Skip to content

Support 'ignore newpage' #633

@dcendents

Description

@dcendents

Hi,

I'm working on a sequence diagram using the newpage instruction and the preview lets me browse through each diagram, very nice.

If I set the instruction ignore newpage at the top of the diagram, I get the error: Error found in diagram sequence numImage is too big = 0 which I suspect comes from the integration and not plantuml itself.

I can generate the diagram (single image) when running it locally with java or using the plantuml server online.
In vscode with local execution I get the error above, with server execution it return Error: 509 but as I said using the plantuml server I have no error.

Looking at the code it looks like you parse the diagram and count how many newpage statements there are (regNewPage = /^\s*newpage\b/i).
I think you could check for /^\s*ignore\s+newpage\b/i and if found then simply return 1 and ignore the newpage statements.

P.S.: I find while I work on a diagram it is easier to generate it in a single page, hence adding the ignore newpage while I work on it and then remove it, otherwise I have to comment all the newpage. It's not a big deal but would be easier.

Thanks,

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions