Oxygen Form Controls Alignment Issues
Oxygen general issues.
-
- Posts: 7
- Joined: Fri Jul 12, 2013 8:54 pm
Oxygen Form Controls Alignment Issues
Post by asynchronousDev »
There seems to be some inconsistencies with the way Oxygen Editor lays out its form controls.
This is a screenshot of how it is rendered. Here you can see that the baseline location of the text would be "author:". The custom form is significantly above the baseline and the button is below the baseline.

This is the CSS we are using to create the form controls:
This is a screenshot of how it is rendered. Here you can see that the baseline location of the text would be "author:". The custom form is significantly above the baseline and the button is below the baseline.

This is the CSS we are using to create the form controls:
Code: Select all
author:before {
margin-left: 2em;
content: "author: "
}
author {
content: oxy_editor(rendererClassName, "com.test.oxygen.plugin.AuthorRenderer",
swingEditorClassName, "com.test.oxygen.plugin.AuthorRenderer",
classpath, "${oxygenHome}/plugins/TestOxygenPlugin/lib/bwater.jar",
columns, 30);
}
author:after {
content: oxy_editor(type, button,
actionID, "choose_author")
}
-
- Posts: 1016
- Joined: Wed Nov 16, 2005 11:11 am
Re: Oxygen Form Controls Alignment Issues
Post by alex_jitianu »
Hello,
The first thing to do would be to check if the custom form control reports a baseline. The InplaceRenderer interface has a method getRenderingInfo(). The returned object, RendererLayoutInfo, has a RendererLayoutInfo.getBaseline(). If this method returns an integer less or equal to 0 then the baseline will be considered the entire height of the control (which will explain the layout you get). To compute a baseline inside your renderer you can delegate to javax.swing.JComponent.getBaseline(int, int).
Best regards,
Alex
The first thing to do would be to check if the custom form control reports a baseline. The InplaceRenderer interface has a method getRenderingInfo(). The returned object, RendererLayoutInfo, has a RendererLayoutInfo.getBaseline(). If this method returns an integer less or equal to 0 then the baseline will be considered the entire height of the control (which will explain the layout you get). To compute a baseline inside your renderer you can delegate to javax.swing.JComponent.getBaseline(int, int).
Best regards,
Alex
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