Reducing the font size in dropdowns,checkboxes,textfield
Post here questions and problems related to editing and publishing DITA content.
-
- Posts: 49
- Joined: Mon Mar 28, 2016 3:54 pm
Reducing the font size in dropdowns,checkboxes,textfield
Post by Raga Mounika »
Hi,
I have created some dropdowns,checkboxes,textfields. To differentiate there attributes from actual content I need to reduce the size of content in dropdown, textfield, checkboxes. But the font here is inherited from parent element. So please help me in reducing the font size for these.
Thanks
Best Regards,
Mounika
I have created some dropdowns,checkboxes,textfields. To differentiate there attributes from actual content I need to reduce the size of content in dropdown, textfield, checkboxes. But the font here is inherited from parent element. So please help me in reducing the font size for these.
Thanks
Best Regards,
Mounika
-
- Posts: 1016
- Joined: Wed Nov 16, 2005 11:11 am
Re: Reducing the font size in dropdowns,checkboxes,textfield
Post by alex_jitianu »
Hi Mounika,
Since these form controls are added on a "before" element, you can use fontInherit as this:
p:before {
font-size:0.6em;
content: oxy_textfield(...., fontInherit, true)
}
Best regards,
Alex
Since these form controls are added on a "before" element, you can use fontInherit as this:
p:before {
font-size:0.6em;
content: oxy_textfield(...., fontInherit, true)
}
Best regards,
Alex
-
- Posts: 49
- Joined: Mon Mar 28, 2016 3:54 pm
Re: Reducing the font size in dropdowns,checkboxes,textfield
Post by Raga Mounika »
Hi Alex,
Thanks for the reply, it works
Consider the example of note element.I am having generated text as "Note:". The code you provided should not impact the generated text and should be applicable for content in dropdown only.Please help me with this as well.
Please go through the code which I used:
Thank you!
Regards,
Mounika
Thanks for the reply, it works

Consider the example of note element.I am having generated text as "Note:". The code you provided should not impact the generated text and should be applicable for content in dropdown only.Please help me with this as well.
Please go through the code which I used:
Code: Select all
*[class~="topic/note"]:before {
content:" Note: ";
font-weight: bold;
}
note:not(*[conkeyref]){
font-size:0.7em;
content :
oxy_combobox(edit , "@type" , editable , false , values , ", ,other,tip" , columns , 7,fontInherit,false) ;
}
/* When other is selected from dropdown we are getting an another dropdown showing do,stop( where DO, Stop are also generated texts) */
note[type="other"]{
font-size:0.7em;
content : oxy_combobox(edit , "@othertype" , editable , false , values , ", Do, Stop" , columns , 7,fontInherit,true) ;
}
Thank you!
Regards,
Mounika
-
- Posts: 1016
- Joined: Wed Nov 16, 2005 11:11 am
Re: Reducing the font size in dropdowns,checkboxes,textfield
Post by alex_jitianu »
Hi Mounika,
You can use multiple pseudo elements:
Best regards,
Alex
You can use multiple pseudo elements:
Code: Select all
*[class ~= "topic/note"]:before(10){
content: " Note: ";
font-weight: bold;
}
note:not(*[conkeyref]):before(5) {
font-size: 0.7em;
content: oxy_combobox(edit, "@type", editable, false, values, ", ,other,tip", columns, 7, fontInherit, true);
}
/* When other is selected from dropdown we are getting an another dropdown showing do,stop( where DO, Stop are also generated texts) */
note[type = "other"]:before(5){
font-size: 0.7em;
content: oxy_combobox(edit, "@othertype", editable, false, values, ", Do, Stop", columns, 7, fontInherit, true);
}
Alex
-
- Posts: 49
- Joined: Mon Mar 28, 2016 3:54 pm
Re: Reducing the font size in dropdowns,checkboxes,textfield
Post by Raga Mounika »
Hi Alex,
Thanks for the code...That really works
Regards,
Mounika
Thanks for the code...That really works

Regards,
Mounika
-
- Posts: 49
- Joined: Mon Mar 28, 2016 3:54 pm
Re: Reducing the font size in dropdowns,checkboxes,textfield
Post by Raga Mounika »
Hi Alex,
I need one more clarification from you.
Is there any possibility to reduce the size of checkbox without impacting the checkbox label?
Similarly to reduce dropdown size also.
Regards
Mounika
I need one more clarification from you.
Is there any possibility to reduce the size of checkbox without impacting the checkbox label?
Similarly to reduce dropdown size also.
Regards
Mounika
-
- Posts: 1016
- Joined: Wed Nov 16, 2005 11:11 am
Re: Reducing the font size in dropdowns,checkboxes,textfield
Post by alex_jitianu »
Hi Mounika,
Let's say you have something like this:
If you want to reduce the size of the combo but keep "My Label" at a bigger size, you can do this:
I hope I understood what you want...
Best regards,
Alex
Let's say you have something like this:
Code: Select all
p:before {
content: "My Label" oxy_combo(....)
}
Code: Select all
p:before {
font-size:12px;
content: oxy_label(text, "My Label", styles, "font-size:20px") oxy_combo(...., fontInherit, true)
}
Best regards,
Alex
Return to “DITA (Editing and Publishing DITA Content)”
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ Artificial Intelligence (AI Positron Assistant add-on)
- ↳ 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