Rank: Member
Groups: Registered
Joined: 11/1/2019(UTC) Posts: 17  Location: Rio de Janeiro Thanks: 2 times
|
I'm trying to highlight some text selected by its object (programmatically). I'm doing the following to get with chars that will be highlighted: Code:viewer.Document.Pages[pageIndex].Text.GetCharIndexAtPos(objectInArea.GetCharRect(i).left, objectInArea.GetCharRect(i).bottom, 0f, 0f);
I've already tried some variations as the following: Code:viewer.Document.Pages[pageIndex].Text.GetCharIndexAtPos(objectInArea.GetCharRect(i).left, objectInArea.GetCharRect(i).bottom, 10f, 10f);
//or
viewer.Document.Pages[pageIndex].Text.GetCharIndexAtPos(objectInArea.GetCharRect(i).left + objectInArea.GetCharRect(i).width/3, objectInArea.GetCharRect(i).bottom + objectInArea.GetCharRect(i).height/3, 10f, 10f);
The chars in black (PAINEL 2) are the ones I'm trying to get the indexes  patagamesOverlap.png (63kb) downloaded 0 time(s).Is there a way to get their index 100% of the time?
|
|
|
|
Rank: Administration
Groups: Administrators
Joined: 1/5/2016(UTC) Posts: 1,087
Thanks: 6 times Was thanked: 127 time(s) in 124 post(s)
|
Hello,
The question is NOT entirely clear. Is this text not accessible through the Text property? Perhaps these are annotations, in which case get it through the page.Annotations collection.
|
|
|
|
Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.
Important Information:
The Patagames Software Support Forum uses cookies. By continuing to browse this site, you are agreeing to our use of cookies.
More Details
Close