News combit Dev Blog

Keeping Groups of Table Lines Together

Posted: Thursday, August 22, 2019 | 0 comment(s)
 
Continuing our quest to make the table object more versatile and powerful in LL25, we added an important tweak to the way table lines are kept together. Before, you just had the choice between keeping all lines together or none. That means, if the output for a single record stretched over a couple of pages and consisted of several line definitions, there was hardly ever a way to get the wrapping "right". 

Often, such a long output will consist of several sections then where a break between some of them would be okay whereas a break within a section would be undesireable. The new LL25 feature allows to handle exactly this situation.

As an example, I've adapted Jeff Atwood's Programmer's Bill Of Rights to be used in a table with free content. The table's line definitions look like this:



and the resulting output looks like this:



Note how the final block gets wrapped right after the header, even though the property "Keep Line Definitions Together" is set to true. The reason is simple - "Keep Line Definitions Together" refers to all lines. List & Label quickly realizes that there's not enough space to keep all lines together and wraps the line definition happily then. However - this is not what you really want here. It would be great to at least be able to keep the headings together with their (non-wrapped) paragraphs. To enable this, simply set the new property "Keep Line Definitions Together > Line Groups" to true. Next, assign a line group index - which is the second part of this new feature - to the lines, making sure the heading and paragraph get the same index:



This way you can select sections that should be kept together rather than the whole block that would never fit anyway. The result of course is then as expected:



This allows a much more flexible approach to the wrapping behavior in List & Label 25. It can also be used e.g. for lengthy invoice footers for keeping taxation information in a block while allowing other footers to float freely.




Author: Jochen Bartlau
Head of Development List & Label

Jochen Bartlau leads the development at combit as Managing Director. He's a Microsoft .NET enthusiast driving innovation & agile project management. The mobile devices geek who used to be a physicist in his first life loves to spend his spare time with his family.


  

+1 800 256 3608 (toll-free North America only)