0

Themes: modifiable, or I’d like to suggest parts of one

fjpoblam 6 years ago in General • updated 6 years ago 3
Suggestion: modifiable themes. Or if you don’t want to bother with that, I have a suggested theme. Why? On my laptop, my editor is BBEdit, and my suggestion will reflect what I’m using there. The goal is to make things easier to find while editing, while remaining somewhat subtle, less garish. The theme I’m using in Textastic is “Mac Classic”, which comes close to my needs. Here’s a description of my ideal theme, for just HTML and CSS. Colors approximate, shown as HTML web-safe names.
HTML:
Text, code punctuation, failed code—black;
tag names (e.g., “<a” of “<a href.…”)—mediumblue (#0000cd)
tag value names (e.g., “href" of “<a href=”)—darkblue (#00008b)
quoted tag values (e.g., “120” of “<img height='120'”)—green (#008000)
unquoted tag values (e.g., “120” of “<img height=120”)—purple (#800080)
entity names (e.g., “&”)—maroon (#800000)
comments (e.g., “<!--…-->”)—darkgray (#a9a9a9)
text and comments—font-weight:normal; else—font-weight:bold;
CSS:
element name (e.g., “p” of “p{color:black}”)—mediumblue (#0000cd)
element value name (e.g., “color” of “p{color:black}”)—darkblue (#00008b)
quoted element value (e.g. “Helvetica Neue” of “p{font-family:'Helvetica Neue'…})—green (#008000)
unquoted element element value (e.g.,“black” of “p{color:black}”)—purple (#800080)
special values (e.g.,“#000” of p{color:#000}”)—maroon (#800000)
comments (e.g., “/*…*/”)—darkgray (#a9a9a9)
failed code (e.g.,“p color: black”)—black
comments—font-weight:normal; else—font-weight:bold
For HTML entities, I intended ampersand amp semicolon
You can already add custom themes to Textastic. This is explained in the manual: http://www.textasticapp.com/v4/manual/lessons/How_...

The "Mac Classic" theme can be found here: https://github.com/kballard/textmate-bundles/blob/...
Superb! Thank you, Alexander Blach. I interrupted coding a new theme to write this reply. (Thanks especially for the “Mac Classic” link.)