Table borders displaying inconsistently in PDF

This forum is for all Flare issues related to styles, stylesheets and XML.
Post Reply
Steveman
Sr. Propeller Head
Posts: 110
Joined: Mon Jul 12, 2010 9:55 pm
Location: Palmerston North, New Zealand

Table borders displaying inconsistently in PDF

Post by Steveman »

Quick question.
In my PDF output some of the internal table borders don't display correctly. Some have thick lines and others thin. It all looks okay in the Editor but not in the output. I'm using Table Styles but I've read a lot of feedback that suggests its not the best way to do it really.

Could it be that other styles override my table style but it just doesn't show until you build output?

If so, I'm not exactly sure how to use the TD, TH sort of styles to make a table. Is there anything available that says "use this style like this to get this kind of output" ? Or does anyone have any examples? My tables are pretty basic.
Carp diem - Seize the fish
LTinker68
Master Propellus Maximus
Posts: 7247
Joined: Thu Feb 16, 2006 9:38 pm

Re: Table borders displaying inconsistently in PDF

Post by LTinker68 »

First, don't put borders on the table tag -- apply borders only to the td and th tags.

Second, there's a known bug in Flare where merged cells have thicker borders than they're supposed to in PDF output. Happens when using table styles and when not using table styles.
Image

Lisa
Eagles may soar, but weasels aren't sucked into jet engines.
Warning! Loose nut behind the keyboard.
Steveman
Sr. Propeller Head
Posts: 110
Joined: Mon Jul 12, 2010 9:55 pm
Location: Palmerston North, New Zealand

Re: Table borders displaying inconsistently in PDF

Post by Steveman »

I'm not sure what the best way to go about adding tables is. At the moment I have a TableStyle that I use to insert the table. Then I change the cell content to be a <p> class that I have created. If I use the Table Styles (td, th etc) from the master style sheet do I specify a font, border type and background etc in there and just make my TableStyle template table a very basic one with no formatting?

So to use a table in this way I'd use my TableStyle table when I go Table>Insert Table to get the right number of rows and columns etc, and then use td, th to format the individual cells in the XML Editor?

I'm new to all this so forgive my bone questions.
Carp diem - Seize the fish
ChoccieMuffin
Senior Propellus Maximus
Posts: 2634
Joined: Wed Apr 14, 2010 8:01 am
Location: Surrey, UK

Re: Table borders displaying inconsistently in PDF

Post by ChoccieMuffin »

Keep asking, Steve, so at least the possibly silly newbie questions aren't all asked by me - and I'd really like to hear the views of the experts on this one.

I'm doing something similar to you though I haven't bothered with the table stylesheet because it was just one step too far, and as my tables are all simple I'm just working the table, th, tr, td and col classes (though you can't apply col classes to columns in the XML editor, only the text editor, which is a pain in the bum.) I have also been putting p classes inside table cells, and sometimes even lists, bullets and graphics.

I'm sure the experts will be back soon to explain properly.
Started as a newbie with Flare 6.1, now using Flare 2023.
Report bugs at http://www.madcapsoftware.com/bugs/submit.aspx.
Request features at https://www.madcapsoftware.com/feedback ... quest.aspx
Steveman
Sr. Propeller Head
Posts: 110
Joined: Mon Jul 12, 2010 9:55 pm
Location: Palmerston North, New Zealand

Re: Table borders displaying inconsistently in PDF

Post by Steveman »

No probs, I'm sure I can think of dozens more dumb questions to save your rep. :wink:

The only reason I used a <p> class inside the cells was because it allowed me to disable hyphenation and also meant I could move the columns around and have the text wrap. As far as I can tell the td style can't do that. (which means it probably does).

But I think my cell border issue could be solved if I use the td stuff and not a "one I prepared earlier" table style.
Carp diem - Seize the fish
ChoccieMuffin
Senior Propellus Maximus
Posts: 2634
Joined: Wed Apr 14, 2010 8:01 am
Location: Surrey, UK

Re: Table borders displaying inconsistently in PDF

Post by ChoccieMuffin »

Rep well and truly beyond salvation, Steve! :D

For simple tables - I don't do complicated ones! - I have assorted table styles in the main stylesheet, things like table.KeepTogether (page-break-inside set to "avoid"), table.BreakBefore (yes, you guessed it, page-break-before set to "always") and all of them with width as 100%, except for table.indent which has left and right margins set (because I want to indent it, funnily enough!) and that then has width as 95%, after a bit of fiddling round and taking a look.

Have you TRIED to change mc-hyphenate to "never" in the td style, or are you just guessing? I'm just asking because I'm curious, not because I know the answer, but I think having attributes to do with text applied to paragraphs rather than to table cells (which for me are "shape" things rather than "text" things) appeals to the DTP person in me, and just seems logical. But it's fine, particularly if you want to have several paragraphs inside a single table cell. As it happens, if you press Return when you're in a table cell, Flare automatically inserts a paragraph. And I wouldn't have discovered that if I hadn't just this second tried fiddling round in Flare, so thanks for getting me to do that - you've saved me loads of time messing around pasting in <p>s all over the place. (Wish I'd worked that out for myself a while back.)

I have also prepared a Template Topic that has examples of tables that I like, for example a table using table.KeepTogether where the first column uses col.Narrow (which I have defined), with both columns having the relevant p class in. I find it quicker to copy a table from the template topic into my new topic rather than having to re-create the table I want each time.

And a good way to avoid messy borders on tables is to just not use borders, but unfortunately that's not a luxury that everyone can afford...
Started as a newbie with Flare 6.1, now using Flare 2023.
Report bugs at http://www.madcapsoftware.com/bugs/submit.aspx.
Request features at https://www.madcapsoftware.com/feedback ... quest.aspx
Steveman
Sr. Propeller Head
Posts: 110
Joined: Mon Jul 12, 2010 9:55 pm
Location: Palmerston North, New Zealand

Re: Table borders displaying inconsistently in PDF

Post by Steveman »

Actually I'll be honest, I've never looked at the 'Advanced' view in the stylesheet. But of course thats where the hyphenate thingy is. And a whole bunch of other stuff that I didn't think Flare did because it wasn't in the Simplified view. (I thought that the Simplified view seemed to apply to me personally)

So I tried making a table using a basic table from my TableStyles and then formatting it using all the table stuff in the Masterstyle sheet. Now in PDF the cell borders are still wrong but they're different ones to what was wrong before. When I say wrong they're not really 'wrong' as such, its just that some borders appear to be slightly more thickerer. (yep, its a word - Google it...)

So I'm no better off really. Might just stick with the prefab tables and use <p> styles in them.
Carp diem - Seize the fish
LTinker68
Master Propellus Maximus
Posts: 7247
Joined: Thu Feb 16, 2006 9:38 pm

Re: Table borders displaying inconsistently in PDF

Post by LTinker68 »

I'd probably still do the borders on the td and th tags, because generally I also apply a bit of padding to those tags so the text doesn't run together. For instance, my paragraphs all have a margin-top attribute but no left and right margins. So when I add them to tables, if the table cells don't have their own padding, then the paragraphs will run into adjacent cells and there won't be any spacing between them. I could use complex selectors to add left and right margins to paragraphs inside table cells, but I'd have to create complex selectors for lists and other tags, too, so it's just easier to put the padding and borders on the td and th tags and let the paragraphs behave as they normally would. Although I do have a complex selector just to set the margin-top of the paragraph to 0 when it's inside a table cell.
Image

Lisa
Eagles may soar, but weasels aren't sucked into jet engines.
Warning! Loose nut behind the keyboard.
hallettc
Jr. Propeller Head
Posts: 1
Joined: Thu Feb 09, 2012 6:28 pm

Re: Table borders displaying inconsistently in PDF

Post by hallettc »

This still doesn't seem to solve the problem of the table rows having lines of varying thicknesses. I'm trying to create table styles that will be used for all our printed manuals, and a table.css seems to be the best way to do that. The different line thicknesses really do not look professional. Is there going to be a fix or workaround I can use?
lacastle
Propellus Maximus
Posts: 1028
Joined: Thu Apr 12, 2007 7:28 am
Location: Wilmington, DE
Contact:

Re: Table borders displaying inconsistently in PDF

Post by lacastle »

have you tried adjusting the magnification in the PDF? (sorry if someone already mentioned that) PDF docs are weird sometimes and magnifications significantly change fonts or line widths.
Post Reply