Copy link to clipboard
Copied
I've read the posts on aligning text in RH 2020.3, but I don't see the alignment options shown in previous posts. On the Table tabl of the Properties panel, my Alignment options are:
That's it. Why don't I see top, middle, or bottom alignment icons?
Copy link to clipboard
Copied
Hi Margaret,
we had that issue some months (and RoboHelp versions) earlier and found a simple solution.
Since the vertical alignment is an attribute of the table row (not the whole table), it has to be set for the <tr> tag. The default attribute is "middle", positioning the cell content in the vertical middle of all cells. That looks strange if the neighboring cells contain much more text, so I figure you want the text to always align at the top of a cell.
Although there are no specific settings in the Editor's panel this can be done manually in the CSS file. If you want the setting to be the default for all table rows, it's just a simple string.
table tr {
vertical-align: top;
}
If you like to handle that behavior depending on the purpose of a table you need to set up different classes for tables. Then change the above string to aim to the classes:
table.oneclass tr {
vertical-align: top;
}
table.anotherclass tr {
vertical-align: bottom;
}
If no class is applied to a table the default 'vertical-align: middle' is still valid.
This is how to add the CSS string:
Now it depends on which of the above cases is yours:
If you want to change the default behavior of all tables just add the code block that does the trick at the bottom of the code sheet:
table tr {
vertical-align: top;
}
If you like to keep the default alignment for all tables and add a different vertical alignment just for a specific class, search for all occurrences of "table" until you detect the class which you want to change.
Then add the vertical-align: top; line before the "}" at the end of the style definition.
Copy link to clipboard
Copied
Copy link to clipboard
Copied
Pressed "Post" too fast, sorry.
After the last step, save the changes, switch back to the Author view, and go back to your topic containing the table you wanted to change. Maybe you need to refresh the topic rendering by saving it and/or pressing the topic's tab again.
Copy link to clipboard
Copied
Hi Margaret,
Modifying the CSS will work. Vertical alignment option is there in the CSS editor but was missing from the Properties panel. We have provided that in Update 4. Pasting the screenshot.
Thanks,
Vivek
Copy link to clipboard
Copied
Thanks, Vivek!
Hi-speed answer as always. We're really looking forward to the next update. Any suggestions when it will be available?
Copy link to clipboard
Copied
Update 4 is now available via Help > Updates.
________________________________________________________
See www.grainge.org for free Authoring and RoboHelp Information