Added option to choose file extension when saving.
Increased maximum size of the toolbar search field.
Added View > Zoom In and View > Zoom Out commands.
When moving by line included child items if the line is folded.
Fix exception when selecting all items and then shifting them left or right.
New project/task/note commands now work at all times, not only when text view has focus.
Printing now prints the current view state (focused project and folds) instead of the entire document.
Delete at start of item will un-indent it (same as Shift-Tab) when item is indented. When no longer indented will join with previous item.
Removed checkboxes in favor of more generic dashes before each tasks. This is a work in progress. Iām still hoping to bring the checkboxes back, but as an option.
Fixed search syntax to recognize ātomorrowā as date keyword instead of misspelled ātommorrowā.
Theme System
This is a first pass. Itās quite possible that Iāll make breaking changes before 3.0.
To edit the theme used in TaskPaper 3:
File > Open Application Folder.
Open the file user.less in a text editorā¦ ideally a programmers text editor that syntax highlights Less syntax.
Make very small changes. And save often, TaskPaper themes are applied immediately when you save to the theme file, so if you make small changes and save often you should make good progress.
Notes
The theme file uses Less syntax, but ONLY syntax. The underlying theme model is much more limited then full HTML/DOM theming. Iām using Less/CSS syntax because itās known and convenient, but Iām targeting my own view objects, not a generic HTML DOM. Iāve provided examples of most things that you can do in the user.less file, so examine that to see whatās possible. And of course let me know when you have questions.
Can you provide some tips for making themes? I see that data-today is a special item type. How would we colorize lines and tags with custom @ tags? Are there other special item/data types for TaskPaper? Forgive my ignorance of LESS. I donāt work with it.
EDIT: Ok, I think I figured out you just put your tag string prefixed with data- like so for a tag @waiting
Have you tried using the embedded syntax rather than two instances of the same tag, as in @person(bill, john) instead of @person(bill) @person(john)? The formatting was failing even before this update, when including two separate instances of the same tag on a single line, but not an issue if you use the comma syntax.
Now if you did want different attributes to be colored differently using a custom theme, youād still be in troubleā¦
Not that I am a pro by any means, not by the longest of shots. But I did encounter this one (avoidable) bug.
That does not work with TaskPaper search syntax for attribute values. A search of @person=bill or @person=john would fail to find either attribute for your example.
This is actually intentional. The attributes map to a key-value store in each item, so thereās only a place to store the first key, otherwise the second would just overwrite.
Less can get pretty complicated and I think TaskPaper themes will be much smaller/simpler then general CSS styling because the target elements and attributes are so much more limited. But with that said Less gives me two things that make creating themes much easier I think.
Unlike CSS it allows you to define @ variables, so I can define a color in one place and use it to style lots of different items.
It allows you to fix two color variables into a third color with the mix function. So for instance if you change the tint-color to red it updates lots of related colors. A feature thatās nice when creating a theme and would be a pain to do in just strait CSS.
Hold up. Are you saying this single attribute/tag key value design is new in TP3? Iāve used this for ages and I believe it still is support in Taskmator which is based on the original TP for iOS. I no longer have the older version of TaskPaper for Mac installed so I canāt check there any longer.
I need to document the API of courseā¦ but matching attributes from styles rules to items I first check item.getAttribute and if thatās empty I also look for a build in property item[attributename] on the item. I think Iāve given examples of most of the useful one for styling in the user.less file.
depth is a calculated property case. data-type is a built in property set by the syntax highlighter. And I think most other useful things would just be user specified tags.
Humā¦ good question. I actually thought TaskPaper 2 worked this wayā¦ but I just checked and it supported your case. I think I must have moved to this dictionary based implementation when starting work on FoldingText many years back nowā¦ thought it was how I always did things.
Anyway the new behavior is very deep in the code, and makes it strait forward to map to more XML and JSON based formats. So that core aspect wonāt change, but I think we can find a good way to support what you are trying to do. Three thoughts:
If you wonāt have namespace problems you could just @bill @john.
As an alternative you could break namespace problems with something like @p-bill @p-john
A more robust solution would are to use @person(bill, john). But right now that wonāt generate the search that you want when clicking the tag values. If you need to find all ābillā youāll need to search for @person contains bill or the shorter form @person bill.
I think probably 3 is the best solution, but it would work a lot better with better syntax support.
My primary request would be to avoid breaking backward compatibility since many tools have been developed based on the older format. I know thatās tough when moving into a new era for TP and I donāt want to be narrow minded. Iād be concerned that many other users have used this approach in other ways. Fortunately for me, I use it for only @waiting and @person. I have seen people that use multiple @project tags with attributes to define tasks that happen to overlap with multiple projects.
For me, I always liked the @person(name) approach because it provided more context for the attribute. Whereas @bill could simply be a task related to paying bills. Additionally, @waiting tells me something about the name and why I care. Iām waiting on someone to do something before proceeding. Obviously there are other more verbose ways to handle this use case.
BTW, Iām definitely not implying that this is a huge problem. Itās mostly an edge case that would be solved by solution #3 above. But thatās a new spec that would not be supported outside of the Mac application.
In long lists I prefer paragraph-spacing for better clarity. In FoldingText I manage this with āmargin-bottom: 0.5remā (between items). Will this be possible with Taskpaper?
I assume this would be where to report bugs on the preview version.
For some reason, in the latest taskpaper list that I created today, when I click on items below the Home level, to focus the list just the items under that Project, the list only displays the Project heading, without the tasks that were displayed when I had the whole list displayed with all projects visible.
Iāve quit and restarted Taskpaper 3 preview and Iāve closed and opened the file in which this is happening. Iām not having this issue with other Taskpaper files open at the same time.
handle-color: mix(#333, @background-color, 15%); // not sure how this one will look on a black background though
guide-line-color: rgba(255,255,255,0); // no guide line
item[data-type="note"] { font-style: normal; color: #999; }