Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Is there a way to resize the columns of a table on Confluence?

Briana Whelan June 16, 2013

When I first created my table the first column needed to be widest, but now I need the last column to be widest and I can't figure out how to specify custom ratios of column sizes

6 answers

8 votes
m
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
June 17, 2013

Total hack but it works and without a plugin.

  1. Go to the column you want set.
  2. Edit the first sentence of the heading (or one that is kind of long).
  3. Locate a space between two words "foo bar" so the space between foo and bar.
  4. Select the space.
  5. Insert < Symbol.
  6. Choose the first symbol which is invisible because it is a no-break space.
    The system pastes it in there.
  7. Repeat for the rest of the spaces in just that first sentence.

There you have it, the hacky way to do this. What this does is fools Confluence into thinking thatfirstsentenceisjustonelongstringofcharacters.

Lester Martin January 29, 2014

works perfectly -- thanks!

Like Max Chernyavskyi likes this
Tony Noto January 30, 2014

Thanks, I've used a similar lower-tech method. I typically have a blank row at the bottom of many of my tables, so in there I'll just put a long string of x's (xxxxxxxxxxxxxxxxxxxxx) based on how wide I want each column. I then highlight the x's and turn the font color to white so they're not visible. They are only visible if someone select the cell/row/table for coping. You could also put this string of x's in the header or first row if you prefer. Seems to work well enough.

RPT Admin
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 2, 2014

Great tip. Thank you.

Mark Bednarski June 16, 2016

Great tip! Still a bummer you can't do this more easily.

Blog Blog November 30, 2018

Very useful tip manthony!

Thanks!

Peter Kidson February 23, 2019

Ah ... it's "insert the first symbol (which is invisible)"
rather than "insert the first symbol  which is invisible)"  :-)
And what's the less-than char there for ?
Cheers


3 votes
PhilB June 16, 2013

I don't believe you can specify column widths with the built-in table construct. However, there are various plugins available that will give you what you need.

The one I've seen most often is the table-plus macro that comes with the Table Plugin for Confluence. Look for it in the marketplace.

Bob Swift OSS (Bob Swift Atlassian Apps)
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
June 17, 2013
1 vote
Jonathan Smith June 22, 2017

This solution is completely manual, but if you are working on a template and have access to source editor (within editing mode <>), you can set the width of the various cells.

example.jpg

0 votes
David Skreiner
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 22, 2016

This issue has a free user macro in the comments (Fabian Meier). It allows one to set the width for all tables on a page without wasting money on a plugin.

https://jira.atlassian.com/browse/CONF-3393

0 votes
Nicolas Casel
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 30, 2015

@manthony

Thanks for this useful tip.

However, what can I do in this specific case: the cell content is a "User id" macro (i.e. it displays user full name according to the userid I've entered when creating the macro block)?

For instance, when source code is:

&lt;p&gt;
	&lt;ac:structured-macro ac:name="profile"&gt;                       
		&lt;ac:parameter ac:name="user"&gt;                  
			&lt;ri:user ri:userkey="1e270f8444cxxxxxxxxxxx"/&gt;
		&lt;/ac:parameter&gt;
	&lt;/ac:structured-macro&gt;                    
&lt;/p&gt;

 

 

0 votes
Mitchell Im June 16, 2013

It's not the cleanest way, but I've found this one to be the simplest. If you're using Confluence 4.1.5+ and are reasonably comfortable with HTML, do the following:

  1. Install the Confluence Source Editor (https://marketplace.atlassian.com/plugins/com.atlassian.confluence.plugins.editor.confluence-source-editor).
  2. Edit your page, and then click on the <> button in the upper right corner to raise a "popup" window with the source of the page.
  3. Find your table in the XHTML, and then tweak it to your heart's content, including using the column width attributes.
Susan Vineyard September 20, 2015

I just installed the Source Editor and it's not letting me make changes to the table. I found a JIRA someone else raised with the same problem. The changes in tables are not saving. Too bad....

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events