It is currently 20 September 2024, 3:10 Advanced search

Header Text ?

Questions and answers on how to best use Instant Developer

Header Text ?

Postby john w » 16 October 2023, 14:58

Is there a way to set the alignment of the header text for a field? I need to right align the text. I have looked at visual styles, etc and do not see a way to do this. You can align the field data but not the header text.

Any suggestion?
Regards

John W
User avatar
john w
 
Posts: 819
Joined: 24 October 2012, 16:29
Location: Apple Valley, Minnesota USA

Re: Header Text ?

Postby ljwilson » 16 October 2023, 20:35

List or Header?
Which Theme (Seattle, Zen, etc)?

I'm sure worst case it could be done with a little css...

...jack
ljwilson
 
Posts: 772
Joined: 26 November 2013, 14:15

Re: Header Text ?

Postby john w » 16 October 2023, 22:44

It is the header text for a numeric field in a detail view. You can align the data just not the header. It would seem like this should be a native feature to InDe, at least in my mind.

I am concerned you are right that it will take CSS to get it resolved. So, before I traveled that path I needed to check to see if I have missed something.
Regards

John W
User avatar
john w
 
Posts: 819
Joined: 24 October 2012, 16:29
Location: Apple Valley, Minnesota USA

Re: Header Text ?

Postby ljwilson » 17 October 2023, 11:45

I must be missing something. I did a quick test in Seattle, and when I right justify the field it does both the header and the value:

2023-10-17_7-43-04.jpg
2023-10-17_7-43-04.jpg (54.73 KiB) Viewed 804 times



2023-10-17_7-43-33.jpg
2023-10-17_7-43-33.jpg (20.43 KiB) Viewed 804 times


...jack
ljwilson
 
Posts: 772
Joined: 26 November 2013, 14:15

Re: Header Text ?

Postby john w » 17 October 2023, 13:54

I am am using Zen and setting the alignment in the properties. I will try it from menu as you have done. It may be what I have missed.
Regards

John W
User avatar
john w
 
Posts: 819
Joined: 24 October 2012, 16:29
Location: Apple Valley, Minnesota USA

Re: Header Text ?

Postby john w » 17 October 2023, 14:44

It does not appear to work with Zen. Air Conditioning (the header) does not right align

HeaderAlign.png
HeaderAlign.png (3.21 KiB) Viewed 788 times
Regards

John W
User avatar
john w
 
Posts: 819
Joined: 24 October 2012, 16:29
Location: Apple Valley, Minnesota USA

Re: Header Text ?

Postby ljwilson » 17 October 2023, 15:12

It only works when the header is on the top, not on the side.

This works for all field headers, list or detail--that may not be what you want though. Tested with Zen.

Put this code in your custom\custom.css file:

Code: Select all
.panel-field-caption-form {
    text-align: right !important;
}


Be sure that you do a hard cache reload with your browser to pickup the css change.

If you only want to do it on certain fields, then you could create your own css class and apply it there.

...jack
ljwilson
 
Posts: 772
Joined: 26 November 2013, 14:15

Re: Header Text ?

Postby john w » 17 October 2023, 16:06

Thanks for the response. I wonder why it works with the header on top but not to the left.

I will give the css a try.
Regards

John W
User avatar
john w
 
Posts: 819
Joined: 24 October 2012, 16:29
Location: Apple Valley, Minnesota USA


Return to Tips & Tricks

Who is online

Users browsing this forum: Majestic-12 [Bot] and 5 guests

cron