Thank you, Mario, for the detailed explanations! 2016-08-29 12:21 GMT+02:00 PMario <pmari...@gmail.com>:
> On Monday, August 29, 2016 at 10:43:35 AM UTC+2, Thomas Elmiger wrote: >> >> I would not recommend to include title-hashes in CSS ... but to somehow >> filter the titles you want to apply special css to and transclude the >> result in the CSS. >> > > "but to somehow filter the titles" ... That's exactly, how it is > implemented in the core atm. If you tag the tiddlers, that you want to > specify with eg: use-me the CSS code is .tc-tagged-use-me > > That works out of the box, in a consistent way. > No additional plugin / documentation is needed. > This gives the user the freedom to define rules in the way they want, > because programmers always use the wrong defaults! > If the user wants to know which tiddlers s/he defined for special > treatment the just need to use <<list-links "[tag[use-me]]">>. > ... > > ------------------------------------------------ > > But we are slightly OT. The OP said: > > >> - *Not modifying the core view template.* >> >> > > The point is. TiddlyWiki implemented a consistent way to modify the UI. > > > a) TW applies default classes to every widget, that create HTML elements, > to allow the built in "palette" and "themes" functionality. > > > b) TW automatically assigns a tag class="" to tiddlers, that are tagged. > So if a user wishes, they can assign special rules to tagged tiddlers. > This was implemented because of high demand. > > > c) TW uses the <$list> widget to dynamically create the core ViewTemplate. > All tiddlers tagged: $:/tags/ViewTemplate are used to build the "top > level" tiddler UI > > some important blocks are: > > > - $:/core/ui/ViewTemplate/title > <http://tiddlywiki.com/#%24%3A%2Fcore%2Fui%2FViewTemplate%2Ftitle> > - $:/core/ui/ViewTemplate/subtitle > <http://tiddlywiki.com/#%24%3A%2Fcore%2Fui%2FViewTemplate%2Fsubtitle> > - $:/core/ui/ViewTemplate/tags > <http://tiddlywiki.com/#%24%3A%2Fcore%2Fui%2FViewTemplate%2Ftags> > - $:/core/ui/ViewTemplate/body > <http://tiddlywiki.com/#%24%3A%2Fcore%2Fui%2FViewTemplate%2Fbody> > > To get the full shadow list. Use: <<list-links [all[shadows]tag[$:/tags/ > ViewTemplate]]>> > > > *If a plugin author wants to add or remove elements*, they can just use > this tag. If a special position within the template is needed the field: > list-before can be used. No need to modify existing core templates! > > $:/core/ui/ViewTemplate/title uses 2 elements to dynamically create the > tiddler toolbar. The system tag: $:/tags/ViewToolbar and a "visibility" > configuration tiddler prefixed: $:/config/ViewToolbarButtons/Visibility/??? > which allows the user (and plugin authors) to decide which elements are > shown by default. > > > Those settings can be changed at: ControlPanel: Appearance: Toolbars > > > *If a plugin author wants to add or remove elements*, they can just use > this tag. If a special position within the template is needed the field: > list-before can be used. If a button needs to be visible by default, just > create the needed config tiddler. No need to modify existing core templates! > > > *-> This mechanism is consistent for all View- and EditTemplates.* > > > >> - Without assigning certain tag to the tiddler. >> - Not using global CSS styles. >> >> d) If all those dynamic mechanisms don't give enough possibilities, every > plugin author is free to create their own UI, with partially or completely > change the default behaviour. Best practice is: modify the core Templates > with your own implementations. > > IMO at a certain point of customization it is needed to modify the core > templates, because ever other possibility is much more fragile, and a lot > more work to maintain. > > > have fun! > > mari > > > > > -- > You received this message because you are subscribed to a topic in the > Google Groups "TiddlyWiki" group. > To unsubscribe from this topic, visit https://groups.google.com/d/ > topic/tiddlywiki/NiS6c9yO-Lg/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > tiddlywiki+unsubscr...@googlegroups.com. > To post to this group, send email to tiddlywiki@googlegroups.com. > Visit this group at https://groups.google.com/group/tiddlywiki. > To view this discussion on the web visit https://groups.google.com/d/ > msgid/tiddlywiki/71de5d61-0d8a-412f-9cd0-6a56d8c3722e%40googlegroups.com > <https://groups.google.com/d/msgid/tiddlywiki/71de5d61-0d8a-412f-9cd0-6a56d8c3722e%40googlegroups.com?utm_medium=email&utm_source=footer> > . > > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "TiddlyWiki" group. To unsubscribe from this group and stop receiving emails from it, send an email to tiddlywiki+unsubscr...@googlegroups.com. To post to this group, send email to tiddlywiki@googlegroups.com. Visit this group at https://groups.google.com/group/tiddlywiki. To view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/CALXLrTgm1-XVNkmyCcKx_5iCFZmTUxfvNm6x9NS6t2e9hhYQfg%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.