Theme Mod Mystery


#1

Long ago I was able to play in the themes under v2. You could try different results by changing theme selection in preferences. Whenever you did that, the whole document would change and reflect the theme you just changed to. The way TP3 is set up, I really don’t understand how to proceed.

First, what theme is my current default? Meaning, what themes is currently running? I show a Themes folder in the application folder as selected in the TP3 menu. That folder contained all my old V2 themes. I have not touched them and I would assume that they are not working in v3 unless I modified them - and I don’t know anything about how to do that.

I have one file at the same level as the Theme folder named “user.less”. I assume that this is my only current (working) theme? However, with no menu to select a theme anymore, how to I test this? I tried a very simple change just to test if I had a working theme that I was modifying. I tested by changing the base text in the document from black to red.

I changed this:
// Base text
@text-color: black;
@background-color: rgb(247, 247, 247);
@font-family: Source Sans Pro;
@line-height-multiple: 1.1;

Into this:
// Base text
@text-color: red;
@background-color: rgb(247, 247, 247);
@font-family: Source Sans Pro;
@line-height-multiple: 1.1;

There is no reason to do this other than I am testing to see if I am affecting the right document - the one I am using. But nothing changes in the current document. I added new text and it is still black. I relaunched Taskpaper and it is still black text - nothing appears to have changed.

What I am comply confused about is, how to tell what theme is being used by TaskPaper. I cannot learn to modify a theme if I have no idea which theme is running or how to switch to a different theme. Maybe I already have it and I am just testing wrong. I would appreciate some clarification.

Thanks


#2

The TaskPaper 3 theme system is much more powerful, yet still in progress when compared to TaskPaper 2. Generally I think it’s much easier to author new TaskPaper 3 themes, but it’s much harder to try out a theme or switch between themes from the end user perspective.

Few notes:

  1. TaskPaper 2 themes are incompatible with TaskPaper 3 … the old TaskPaper 2 themes in your TaskPaper folder are just ignored.

  2. TaskPaper 3 has no UI support for themes (i.e. no theme menu with switching)

You are on the right track, but user.less was actually the theme name for one of the TaskPaper 3 betas. You should also see a file named theme.less in that folder. If you make the same change to that file then things should work I think. See this page for a step by step guide:

http://guide.taskpaper.com/creating_themes.html


#3

The user.less is the only one that has code in it. The theme.less document only contains this line:

// See http://guide.taskpaper.com/creating_themes.html to get started.

Is that my problem here? Should I just cut and paste the date in user.less into theme.less and delete the user.less? I suppose that it is just in default mode if it is still looking only for theme.less and theme.less has nothing in it?

ADDED: Yep, that did it alright. I guess that old beta user.less file was throwing me off the trail. I can now see changes playing in theme.less. Hooray!


#4

:slight_smile:!

One thing that has changed from the beta is that you don’t need to include all those rules in your theme file. There’s a default theme built into TaskPaper.app, theme.less just customizes it. So for instance you could just put:

@text-color: red;

As the only content in theme.less and it would work OK. I recommend that you only add style rules for things that you want different from the default theme. So start small and just add rules for what you want to change.


#5

That’s interesting, thanks.

Finally I can start to tweak this thing. Yay!

I have my items with the tag “task” set to color red. When I click them to done and then archive them, I don’t want to scan visually and see red items down in archives. I want red to flag visually that something still needs to be done.

item[data-type=project] {
font-size: 18;
color: rgb(42, 84, 165);
}

item[data-task] {
color: rgb(255, 0, 0);
}
item[data-whyputoff] {
color: rgb(42, 84, 165);
}

item[data-done] {

run[display] {
text-strikethrough: NSUnderlineStyleSingle;
text-strikethrough-color: rgb(100, 100, 100);
}
}

item[data-done] {
color: rgb(100, 100, 100);
}


#6

If I understood correctly, some of the things you want to theme are conditional. Because of the nature of TaskPaper and how themes work, that is not something that can be done without reworking several major components in TaskPaper. Maybe the Script route is a better route all together.