Question Regarding Padding

8 views
Skip to first unread message

Oscar

unread,
May 14, 2020, 8:12:36 PM5/14/20
to Orbeon Forms
Hi all,

I am trying to add padding to a button on a from. Can this be accomplished?

The butoon defaults to the top of the row. I would like to add padding to center the button both on height and width. Is this something that could be done?


I have attached a screenshot of the current button position

Alessandro Vernet

unread,
May 15, 2020, 12:07:09 AM5/15/20
to orb...@googlegroups.com
Hi Oscar,

I'd recommend you do this in CSS. Hopefully you have someone in-house who is
familiar with CSS (or maybe you are a CSS wiz yourself), and that can do
this. To setup your own CSS for your forms, see:

https://doc.orbeon.com/form-runner/styling/css

You'll let me know if this works for you!

‑Alex

-----
--
Follow Orbeon on Twitter: @orbeon
Follow me on Twitter: @avernet
--
Sent from: http://discuss.orbeon.com/

Oscar

unread,
May 15, 2020, 1:57:58 PM5/15/20
to Orbeon Forms
Alex,

Thank you for the information.

I have a question regarding the example of the strength rule.

This is the example on the website:

.orbeon .fr-grid .my-class .xforms-input-input {
    ...rule...
}

Is the .my-class section the class specified under the control's settings for custom CSS class?

If so would the following control be:

.orbeon .fr-grid .button xfoms-Clickbutton{
rule
}


Her are the control settings:

Thank you for your help!

Regards,
Oscar

Alessandro Vernet

unread,
May 16, 2020, 1:58:38 AM5/16/20
to orb...@googlegroups.com
Hi Oscar,

You mention the following selector: `.orbeon .fr-grid .button
xfoms-Clickbutton`. Here, `button` is the class name you specified for that
control in the Control Settings dialog, so that part is correct. However,
`xfoms-Clickbutton` isn't correct; there will be no such class in the DOM.
Instead of trying to predict and visualize what the DOM looks like, I highly
recommend you just look at it with Dev Tools. And there you can also see if
your CSS works, and change it live to get the effect you need. I hope this,
or rather the Dev Tools, helps!

Oscar

unread,
May 20, 2020, 4:03:13 PM5/20/20
to Orbeon Forms
Thanks Alex.

This helped a lot!

Regards,

Oscar

Alessandro Vernet

unread,
May 21, 2020, 1:16:38 PM5/21/20
to orb...@googlegroups.com
Excellent Oscar; I'm glad you made good progress on that CSS.
Reply all
Reply to author
Forward
0 new messages