Skip to main content
13-Aquamarine
July 1, 2015
Solved

How to define style for processing instructions in Arbortext Editor Styler?

  • July 1, 2015
  • 1 reply
  • 1367 views

Hi,

does anybody know if it is possible to define e.g. another colour for Processing instructions? Our customer use processing instructions, and sometimes users accidentely delete this pi's. Therefore we would like to define the pi's with red colour.

Unfortunately we did not found anything in the Arbortext Styler to do this. We fear that this is not possible.

Anybody an idea?


Thank you in advance.

Best answer by ClayHelberg

You can do this in Styler by adding an element called "_pi". That will catch all PIs, and you can color them by modifying the Text Shading attribute.

If you need to be more selective, e.g. use different colors for different PIs, you can do that by adding conditions. Use an XPath condition like this:

     self::processing-instruction("NameOfPi")

That will capture all instances of <?NameOfPi?> and apply formatting to them.

1 reply

18-Opal
July 1, 2015

You can do this in Styler by adding an element called "_pi". That will catch all PIs, and you can color them by modifying the Text Shading attribute.

If you need to be more selective, e.g. use different colors for different PIs, you can do that by adding conditions. Use an XPath condition like this:

     self::processing-instruction("NameOfPi")

That will capture all instances of <?NameOfPi?> and apply formatting to them.

hbestler13-AquamarineAuthor
13-Aquamarine
July 6, 2015

Hi Clay,

perfect! thank you!!! That was absolutely what we are searching for!!

It is interesting, that the official german support of PTC told us, that this is not possible

PTC Community is in future the first contact point for me