kvinwang / evoluspencil

Automatically exported from code.google.com/p/evoluspencil
0 stars 0 forks source link

Improve font drop downs #185

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Enhancement

In all font drop down lists, the font names should be written using the font 
itself.

I have changed it in the source code by myself, by adding the following lines 
to chrome/content/Editor/OnScreenTextEditor-RichTextSupport.js

item.setAttribute("style", "font-family: " + localFonts[i]);
item1.setAttribute("style", "font-family: " + localFonts[i]);

Please see the result in the attached screen shot.

(Currently selected value should be modified accordingly too, not done yet in 
the screen shot)

But it's my first time I'm looking into XUL development, so I'm not quite sure 
if it's the correct way to do it.

There are multiple font lists set up in the code at different places.
(afaik ~ 4 times, e. g. PageNoteDialog.js, RichTextDialog.js, ...)

Maybe there's the chance to modify all font drop downs at once without copying 
the code to each?

Original issue reported on code.google.com by KrosseKr...@gmail.com on 29 Jun 2010 at 10:29

Attachments: