1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2024-12-04 07:19:56 +00:00
TiddlyWiki5/plugins/tiddlywiki/dynaview/examples/font-optisizer.tid
Jermolene dbfe28094c DynaView plugin: Add font "optisizer"
A mechanism to choose the optimum font size of a passage of text to yield a particular numbr of characters per line.

@BurningTreeC I've made some minor consistency tweaks and cleanups to the viewport stuff, too.
2018-03-10 10:33:34 +00:00

18 lines
792 B
Plaintext

title: $:/plugins/tiddlywiki/dynaview/examples/font-optisizer
tags: $:/tags/dynaviewExamples
caption: Font Optisizer
<$button>
<$action-setfield $tiddler="$:/config/DynaView/Optisizer" $value="yes"/>
<$action-setfield $tiddler="$:/themes/tiddlywiki/vanilla/metrics/bodyfontsize" $value="{{$:/state/DynaView/Optisizer/FontSize}}"/>
<$action-setfield $tiddler="$:/themes/tiddlywiki/vanilla/metrics/bodylineheight" $value="1.5"/>
Enable font optisizer for tiddler body text
</$button>
<$button>
<$action-setfield $tiddler="$:/config/DynaView/Optisizer" $value="no"/>
<$action-setfield $tiddler="$:/themes/tiddlywiki/vanilla/metrics/bodyfontsize" $value="14px"/>
<$action-setfield $tiddler="$:/themes/tiddlywiki/vanilla/metrics/bodylineheight" $value="20px"/>
Disable font optisizer
</$button>