How to Use a Custom Stylesheet
Beauty, they say, is in the eye of the beholder. And while the aesthetics of a document may not be the most critical component, having a pleasant to read a document certainly doesn’t hurt. Markdown is written in plain text but renders like web content and can be enhanced with CSS styling. Here’s how to add default styling to some of your documents in DEVONthink and DEVONthink To Go.
A default stylesheet applies its styling to all Markdown or HTML-based documents in DEVONthink. So if you add a lime-green background color in the stylesheet, each Markdown document you look at in DEVONthink will have the colored background. This can be very useful if you have a certain set of fonts or colors you prefer to see in the document. Also, if you should later decide to change your mind, you can change the default styling without having to edit all your documents individually.
In DEVONthink, choose the default stylesheet for Markdown documents in Settings > Files > Markdown > Style Sheet. For HTML-based documents, e.g., formatted notes, use Settings > Web > Style Sheet. In DEVONthink To Go, you can’t link to an external stylesheet, but you can create the default styling in its Settings > Markdown > Additional CSS. Alternatively, create a plain text document in any of your databases, grab its item link, and paste the item link into the CSS text field to use this document as the stylesheet.
You can find many free stylesheets on the Internet, if you just want something nice pre-made. One site of inspirational stylesheets is CSS Zen Garden. And a search for something like “free css stylesheets” will yield thousands of possibilities.
For those inclined to deeper investigation or want to roll their own, there are many tutorials available on creating stylesheets. In fact, one of our forum friends, @chrillek posted a nice primer on CSS and styling. Start here: CSS for Markdown, the basics.
Regarding DEVONthink specifically, there is also a forum post illustrating how using a default stylesheet and other options, like internal styling, affect each other. This allows even more customization of individual documents while still maintaining some default formatting. You can read that here: A Matter of Style - Markdown.
We hope this helps make your documents a little more beautiful to work with.