Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Block/Layer name #36

Open
som3on3 opened this issue Jul 11, 2024 · 1 comment
Open

Block/Layer name #36

som3on3 opened this issue Jul 11, 2024 · 1 comment

Comments

@som3on3
Copy link

som3on3 commented Jul 11, 2024

using var ctx = new MuPDFContext();
using var document = new MuPDFDocument(ctx, "source.pdf");

var page = document.GetStructuredTextPage(0);
foreach (var block in page) {
    // how to get layer name??
}

How to get the layer name from block?

@arklumpus
Copy link
Owner

Hi! I think you are referring to optional content groups (sometimes also known as layers), right? I.e., bits of content that can be toggled on and off in the PDF viewer interface. If this is the case, these are not currently supported by this library, but I can work on it as soon as I have a bit of time.

The structured text blocks you get from the structured text page are completely unrelated to this. Also note that the MuPDFStructuredTextPage class implements IDisposable, therefore you should also make sure that it is Disposed - e.g., with using var page = document.GetStructuredTextPage(0);

I will leave this issue open until I manage to look at implementing optional content groups!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants