You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It seems it is not possible to easily have multiple columns with multiple formats.
At the moment you can have a long text split in multiple columns if you have:
A workaround is to use the continued option for the first (or both) instructions. This will make longText2 effectively follow longText1.
However, it seems it is not possible to have a line break between the 2 texts, that is, continue in the same column, but after a new line, to five a sense of different paragraph (texts with new lines at the end are simply trimmed).
Would it be possible to introduce a newLine() which continues the same column section, but adds the test on a new line with some indent?
I've created a PR which introduces a new option, lineBreakAfter, which simply adds a new line to the text before closing a section and starting the new continued one. It seems to work, but maybe a specific function would be simplet to use. Also, I managed only to have it working introducing the new line after the text, not before. I believe it would be useful to let the user decide whether to have the text forcing a new line after it, or a new text starting on a new line, depending on the cases.
Let me know if the PR could be useful, so that I can add more documentation.
The text was updated successfully, but these errors were encountered:
Feature Request
Feature description
It seems it is not possible to easily have multiple columns with multiple formats.
At the moment you can have a long text split in multiple columns if you have:
doc.text(longText, {align: 'justified', columns: 3, columnGap: 15})
However, 2 subsequent text() call will create 2 distinct areas of 3 columns and longText2 will not continue from the same column of longText1.
A workaround is to use the continued option for the first (or both) instructions. This will make longText2 effectively follow longText1.
However, it seems it is not possible to have a line break between the 2 texts, that is, continue in the same column, but after a new line, to five a sense of different paragraph (texts with new lines at the end are simply trimmed).
Would it be possible to introduce a newLine() which continues the same column section, but adds the test on a new line with some indent?
I've created a PR which introduces a new option, lineBreakAfter, which simply adds a new line to the text before closing a section and starting the new continued one. It seems to work, but maybe a specific function would be simplet to use. Also, I managed only to have it working introducing the new line after the text, not before. I believe it would be useful to let the user decide whether to have the text forcing a new line after it, or a new text starting on a new line, depending on the cases.
Let me know if the PR could be useful, so that I can add more documentation.
The text was updated successfully, but these errors were encountered: