Andy Black wrote:
> In a project I'm working on, we allow an author to create an "object"
> element which has an IDREF to a "type" element.  These "type" elements
> have various font-related attributes.  The idea is that our XSLT
> transforms convert these attributes to whatever the target of the
> transform needs (e.g. CSS or XSL-FO).  In this way, the user can tag the
> object as a type and then control how it will render via the attributes
> on the type element.  Our language elements also have these font
> attributes.
> 
> I'm wondering if there is a way within the configuration files to create
> a macro that can access the font drop-down chooser that XXE has under
> Options / Options / View.
> 
> Similarly, I'm wondering if there is a way to create a macro that can
> access the color dialog box that also is in Options / Options / View.
> 

Yes. But you need to write two *very* *simple* commands in Java[tm].
http://www.xmlmind.com/xmleditor/_distrib/doc/dev/command.html

Command #1: selectColor (optional parameter: a color in CSS syntax;
returns a color in CSS syntax) basically displays the standard Swing
JColorChooser.

Command #2: selectFont (optional parameter: a font in CSS syntax;
returns a font in CSS syntax) basically displays our own
com.xmlmind.xmledit.guiutil.FontChooserDialog (there is no standard
Swing JFontChooser). See attachment.

Now that you have written these two commands, you can use them to create
really useful macros.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: fontchooserdialog.png
Type: image/png
Size: 6713 bytes
Desc: not available
Url : 
http://www.xmlmind.com/pipermail/xmleditor-support/attachments/20060803/5c016594/attachment.png
 

Reply via email to