oxy-label()
Oxygen general issues.
-
- Posts: 206
- Joined: Thu Dec 01, 2011 4:22 pm
- Location: Hamburg, Germany
Re: oxy-label()
Hello Radu,
is this oxy_label() function also available in a StylesFilter?
So that I can distinguish between the CSS content by for instance changing its color?
Could you please explain how it can be used?
Currently I add new CSS content like that:
It would be nice if the style of the existingMixedContent could stay the same and the new StringContent("New Content") could be styled separately like it is done with the oxy_label() function.
Best regards,
Simon
is this oxy_label() function also available in a StylesFilter?
So that I can distinguish between the CSS content by for instance changing its color?
Could you please explain how it can be used?
Currently I add new CSS content like that:
Code: Select all
StaticContent[] existingMixedContent = styles.getMixedContent();
StaticContent[] newStaticContent = mergeStaticContents(existingMixedContent,
new StringContent("New Content"));
styles.setProperty(Styles.KEY_MIXED_CONTENT,
newStaticContent);
Best regards,
Simon
Simon Scholz
vogella GmbH
http://www.vogella.com
vogella GmbH
http://www.vogella.com
-
- Posts: 9445
- Joined: Fri Jul 09, 2004 5:18 pm
Re: oxy-label()
Hi Simon,
Actually one class which implements StaticContent is called ro.sync.ecss.css.LabelContent which takes a map of properties on the constructor but right now it is obfuscated in our JAR library. I'll fix this in our code and try to push the changes in the next 14.2 minor bug fix release.
Regards,
Radu
Actually one class which implements StaticContent is called ro.sync.ecss.css.LabelContent which takes a map of properties on the constructor but right now it is obfuscated in our JAR library. I'll fix this in our code and try to push the changes in the next 14.2 minor bug fix release.
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 206
- Joined: Thu Dec 01, 2011 4:22 pm
- Location: Hamburg, Germany
Re: oxy-label()
Hi,
Well done, the ro.sync.ecss.css.LabelContent works.
Just one little enhancement would be great for the LabelContent class.
Could you provide some constants in your LabelContent class for the Map, which is passed to the LabelContent?
That would be better than putting plain Strings as keys to the Map.
I mean those keys defined here:
http://www.oxygenxml.com/doc/ug-oxygen/ ... ction.html
So it would for you be easier to modify the keys without breaking code of customers and I do not have to define those constants myself or always have to lookup the http://www.oxygenxml.com/doc/ug-oxygen/ ... ction.html manual.
Best regards,
Simon
Well done, the ro.sync.ecss.css.LabelContent works.

Just one little enhancement would be great for the LabelContent class.
Could you provide some constants in your LabelContent class for the Map, which is passed to the LabelContent?
That would be better than putting plain Strings as keys to the Map.
I mean those keys defined here:
http://www.oxygenxml.com/doc/ug-oxygen/ ... ction.html
So it would for you be easier to modify the keys without breaking code of customers and I do not have to define those constants myself or always have to lookup the http://www.oxygenxml.com/doc/ug-oxygen/ ... ction.html manual.
Best regards,
Simon
Simon Scholz
vogella GmbH
http://www.vogella.com
vogella GmbH
http://www.vogella.com
-
- Posts: 9445
- Joined: Fri Jul 09, 2004 5:18 pm
Re: oxy-label()
Hi Simon,
You should find constants in the ro.sync.ecss.css.functions.LabelCSSConstants class which should also be not obfuscated.
Regards,
Radu
You should find constants in the ro.sync.ecss.css.functions.LabelCSSConstants class which should also be not obfuscated.
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 206
- Joined: Thu Dec 01, 2011 4:22 pm
- Location: Hamburg, Germany
Re: oxy-label()
Hi Radu,
unfortunately it seems that the ro.sync.ecss.css.functions.LabelCSSConstants are obfuscated.
Could you please also make the LabelCSSConstants non obfuscated?
Best regards,
Simon
unfortunately it seems that the ro.sync.ecss.css.functions.LabelCSSConstants are obfuscated.

Could you please also make the LabelCSSConstants non obfuscated?
Best regards,
Simon
Simon Scholz
vogella GmbH
http://www.vogella.com
vogella GmbH
http://www.vogella.com
-
- Posts: 9445
- Joined: Fri Jul 09, 2004 5:18 pm
Re: oxy-label()
Hi Simon,
Right, sorry about that, it was already exposed in our source code. I also added it as exposed on the 14.2 branch so if we make another minor release kit the interface will be not obfuscated in it.
Regards,
Radu
Right, sorry about that, it was already exposed in our source code. I also added it as exposed on the 14.2 branch so if we make another minor release kit the interface will be not obfuscated in it.
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 206
- Joined: Thu Dec 01, 2011 4:22 pm
- Location: Hamburg, Germany
Re: oxy-label()
Hello Radu,
in some cases we add a line break to the :BEFORE content.
When I passed text with line breaks to the ro.sync.ecss.css.StringContent.StringContent("text with line breaks") those line breaks are shown, like it is expected.
But when I use the ro.sync.ecss.css.LabelContent, the line break are not shown.
Could be please fix this problem, so that the ro.sync.ecss.css.LabelContent also supports line breaks?
Best regards,
Simon
in some cases we add a line break to the :BEFORE content.
Code: Select all
public static final String SYSTEM_LINE_BREAK = System.getProperty("line.separator"); //$NON-NLS-1$
But when I use the ro.sync.ecss.css.LabelContent, the line break are not shown.
Code: Select all
Map<String, Object> labelContentMap = new HashMap<String, Object>();
labelContentMap.put("text", "text with line breaks");
labelContentMap.put("color", this.color);
LabelContent labelContent = new LabelContent(labelContentMap);
Best regards,
Simon
Simon Scholz
vogella GmbH
http://www.vogella.com
vogella GmbH
http://www.vogella.com
-
- Posts: 1016
- Joined: Wed Nov 16, 2005 11:11 am
Re: oxy-label()
Post by alex_jitianu »
Hi,
I've added an improvement request to enable line breaks support in oxy_label. Until then, as a workaround, you could split the text by line breaks and create a LabelContent for each token and a StringContent for each line break, like this:
Best regards,
Alex
I've added an improvement request to enable line breaks support in oxy_label. Until then, as a workaround, you could split the text by line breaks and create a LabelContent for each token and a StringContent for each line break, like this:
Code: Select all
StaticContent[] content = new StaticContent[] {
new LabelContent(token1Properties),
new StringContent("\n"),
new LabelContent(token2Properties)};
styles.setProperty(Styles.KEY_MIXED_CONTENT, content);
Alex
-
- Posts: 9445
- Joined: Fri Jul 09, 2004 5:18 pm
Re: oxy-label()
Hi Simon,
Oxygen 15.0 was just released and should allow an oxy-label to split on multiple lines if it has new lines in it.
You'll probably receive a notification email for the new release in a couple of days.
Regards,
Radu
Oxygen 15.0 was just released and should allow an oxy-label to split on multiple lines if it has new lines in it.
You'll probably receive a notification email for the new release in a couple of days.
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 9445
- Joined: Fri Jul 09, 2004 5:18 pm
Re: oxy-label()
Just to update the thread:
The initial post in this thread was about being able to add more styles like font-weight to the oxy_label and that also became possible in Oxygen 15.0.
http://www.oxygenxml.com/doc/ug-oxygen/ ... ction.html
Regards,
Radu
The initial post in this thread was about being able to add more styles like font-weight to the oxy_label and that also became possible in Oxygen 15.0.
http://www.oxygenxml.com/doc/ug-oxygen/ ... ction.html
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service