-
1. Re: Auto fit table in object frame?
P Spier May 22, 2010 6:46 AM (in response to auctioneer)I'm having some trouble seeing this without an image, but there is no "autofit" property other than how the table fits the frame width when first created.
Holding the Shift key while moving the far-right or bottom cell edge will resize all columns or rows proportionally, if that helps. Holding shift while moving an inner edge leaves the overall table dimension the same and adjusts the width/height of adjacent columns/rows
-
2. Re: Auto fit table in object frame?
auctioneer May 22, 2010 6:55 AM (in response to P Spier)It would appear the stroke is causing me the grief. What I think I need to do is stack the objects, therefore set the exact dimensions for the stacked objects at 7.5" without stroke, bring them together and then apply the stroke to the 1st upper object and 2nd to the table below, alignment should be exact. (?) which brings me to more problems. How do I set the exact width of the table (7.5") and how do I center align both objects?
Thanks..
-
3. Re: Auto fit table in object frame?
[Jongware] May 22, 2010 7:17 AM (in response to auctioneer)It's still a bit unclear. How about an image? (Use the Camera Icon on the web forum to insert images.)
This Javascript sets the width of the table the cursor is in to 7.5" exactly:
if (app.selection.length == 1) { myTable = app.selection[0]; if (myTable.hasOwnProperty ("baseline")) myTable = myTable.parent; if (myTable instanceof Cell) myTable = myTable.parent; if (myTable instanceof Row) myTable = myTable.parent; if (myTable instanceof Column) myTable = myTable.parent; if (myTable instanceof Table) myTable.width = "7.5 in"; } -
4. Re: Auto fit table in object frame?
P Spier May 22, 2010 7:19 AM (in response to auctioneer)Is this what you mean?
I made a text frame and adde a stroke, aligned to the outside. Next I inserted a table and adjusted the dimensions. Finally added a fill to the cells and the stroke to the cell borders (I'm not good with tables, so I ended up having to go back and select the entire table again and set the stroke width of the outer border to 0).
-
5. Re: Auto fit table in object frame?
auctioneer May 22, 2010 6:24 PM (in response to P Spier)This is the doc I'm working on. I've managed to align the upper and lower sections, but it was a lot of effort. It seems to me there has to be a better way other than using the 'text' tool to make the 2 objects align perfectly.
Now having seen what I'm trying to achieve how would you approach these alignment issues?
Thanks...
-
6. Re: Auto fit table in object frame?
RodneyA May 24, 2010 6:19 AM (in response to auctioneer)I'd drag out some guides to mark the left and right margins, and make sure that View:Grids and Guides:Snap to Guides is on. Then I'd create a text frame and align its edges with the guides, then create a table in it that aligns with the edges of the text frame. Make sure that the paragraph holding the table is aligned left rather than center, since that makes it easier to make the table match the frame width exactly.
If you've got to create this table again and again for different chapters or documents, I'd take the entire table-containing text frame, once it's perfect, and add it to a Library so that you can easily retrieve a copy when you want.





