From: Paul A. Rubin <[email protected]> Sent: Sunday, January 26, 2020 16:11 To: Bernt Lie <[email protected]>; [email protected] Subject: Re: Table row alignment?
On 1/26/20 9:49 AM, Bernt Lie wrote: From: lyx-users <[email protected]><mailto:[email protected]> On Behalf Of Paul A. Rubin Sent: Saturday, January 25, 2020 21:49 To: [email protected]<mailto:[email protected]> Subject: Re: Table row alignment? On 1/21/20 3:58 AM, Bernt Lie wrote: I use LyX 2.3.3 on 64bit Windows 10, latest version. I have a floating table with 3 columns. In the first column, I have a figure, in the second column I need to rows of equations, and in the third column, I have a text line: [cid:[email protected]] To get two rows of equations in a sigle table cell, I inserted a 2x1 table within the cell, and inserted a single-line equation in each sub cell. [If I instead insert a multiline equation in the cell, LyX preview crashes.] My main problem is that I find it “ugly” that the three columns in the row (figure, two lines of equations, and text line] don’t align up well, horizontally. I have tried to choose the row containing the cylinder, the equations (Jz = ½*m..., Jx = Jy = ...), and the text (“Hollow cylinder...”), and select, say, top alignment, or centered alignment, but those icons/choices are disabled. Is there a way to control the horizontal alignment? Thanks. -B Without a MWE on which to experiment, it's hard to be certain. A couple of possibilities come to mind. One is to replace the 2x1 inner table with a multiline math formula (such as a "gathered" environment). Another is to click in a cell in the first column¸ click Edit > Table Settings (or right click and do the equivalent), set a fixed width for the first column and a vertical alignment of "Middle" in the column settings dialog. Paul -- I have attached a minimal LyX document with the *.svg file that I use. In the figure path of LyX, I have put the figure in a subdirectory “figs” – which can easily be changed. I’ve tested a bit more, and it is the insertion of the *figure* that causes the problem. My “trick” of getting multiline math by inserting a table within a table cell works fine. So: is it possible to vertically center the figure at the insertion point? -B What I proposed above works. Put the cursor in the "Geometry" cell, right click, select Settings..., and in the Column settings section of the Table Settings tab set a fixed width for the column. That enables the Vertical alignment control, which you set to Middle. You might want to horizontally center as well; that's up to you. I've attached a modified version of the MWE. Paul Thanks! I get it! I need to *specify width* in order to *enable vertical alignment* -- at least for cells with graphics. -B
-- lyx-users mailing list [email protected] http://lists.lyx.org/mailman/listinfo/lyx-users
