On Sun, Jul 9, 2017 at 9:06 AM, vitalije <[email protected]> wrote:
Well in current implementation if c.p is an `@font node`, command simply > adjust body, there is IMHO no need to alter clipboard. > That's fine. > But if it is not `@font node`, if I understand correctly your advise is to > put definition in clipboard? > Such choices are yours to make. > It has only one simple drawback that I also wanted to reconsider design of > `@font node` settings. Currently `@font node` has to have in body name of > setting repeated several times. For example if node is to define > keyword1_font > it has to have in body > keyword1_font_family, keyword1_font_weight, keyword1_font_slant and > keyword1_font_size > > It complicates parsing and it leaves more space for typing mistakes. It > would be better (IMHO), if we put keyword1 in headline, after `@font` and > in body leave just `family, weight, slant and size`. leoConfig parser can > deduce full settings names joining name from headline with values in body. > We could do this only if it is compatible with existing @settings trees. If show-fonts should make definition outside `@font node` and put it in > clipboard it is name that is not known at that time, and definition from > clipboard would be useless. > Maybe this part of my suggestion was wrong. Please do whatever you want, provided that you warn people if a command expects c.p to be a particular kind of settings node and isn't. > If we change syntax of `@font` nodes definition in body could be copied > and pasted in other nodes without any changes and show-fonts could make > definition in clipboard ready to be pasted anywhere. > I think we are stuck with the existing syntax. Let's not create complex compatibility problems merely to support a minor command. If you really want to copy settings to the clipboard, you can do so without changing syntax. Edward -- You received this message because you are subscribed to the Google Groups "leo-editor" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/leo-editor. For more options, visit https://groups.google.com/d/optout.
