D21266: [WIP] Improve documentation of area classes

2019-06-24 Thread David Hurka
davidhurka marked 2 inline comments as done. davidhurka added a comment. Changed 3 more lines yesterday. Now removing [WIP]; I have some remaining questions (inline coments without “done”), but these are not important for this patch. INLINE COMMENTS > aacid wrote in area.h:224 > same as

D21266: [WIP] Improve documentation of area classes

2019-06-23 Thread David Hurka
davidhurka updated this revision to Diff 60536. davidhurka added a comment. - Describe consequences of negative width/height - Add note to RegularArea::contains() concerning simplify() REPOSITORY R223 Okular CHANGES SINCE LAST UPDATE https://phabricator.kde.org/D21266?vs=60388=60536

D21266: [WIP] Improve documentation of area classes

2019-06-23 Thread David Hurka
davidhurka marked 14 inline comments as done. REPOSITORY R223 Okular BRANCH improve-area-classes-documentation REVISION DETAIL https://phabricator.kde.org/D21266 To: davidhurka, #okular, aacid Cc: aacid, okular-devel, fbampaloukas, joaonetto, tfella, ngraham, darcyshen

D21266: [WIP] Improve documentation of area classes

2019-06-22 Thread David Hurka
davidhurka updated this revision to Diff 60388. davidhurka added a comment. - Small improvements based on latest comments by Albert. REPOSITORY R223 Okular CHANGES SINCE LAST UPDATE https://phabricator.kde.org/D21266?vs=59149=60388 BRANCH improve-area-classes-documentation REVISION

D21266: [WIP] Improve documentation of area classes

2019-06-22 Thread David Hurka
davidhurka marked 12 inline comments as done. davidhurka added a comment. Thanks for marking the typos. I tried to use your latest comments for improvements, without changing much else. (In the end I changed only 3 sentences.) INLINE COMMENTS > aacid wrote in area.h:214 > what if they

D21266: [WIP] Improve documentation of area classes

2019-06-22 Thread Albert Astals Cid
aacid accepted this revision. aacid added a comment. This revision is now accepted and ready to land. There's a few typos and i think i don't really agree with the "rectangles should not have negative width/height" wording, they don't make much sense, but on principle don't tell people what

D21266: [WIP] Improve documentation of area classes

2019-06-04 Thread David Hurka
davidhurka updated this revision to Diff 59149. davidhurka marked an inline comment as done. davidhurka edited the summary of this revision. davidhurka added a comment. Removed references to pages from methods. Now they refer to a reference area, and the description of the normalized

D21266: [WIP] Improve documentation of area classes

2019-06-02 Thread David Hurka
davidhurka marked 4 inline comments as done. davidhurka added inline comments. INLINE COMMENTS > aacid wrote in area.h:108 > i don't know, you may want to ask Peter, but it was 6 years ago, i doubt he > remembers. > > What's your problem with it being static? It would make sense to make it

D21266: [WIP] Improve documentation of area classes

2019-06-02 Thread David Hurka
davidhurka marked 10 inline comments as done. davidhurka added a comment. I will remove page sizes from member documentations and describe the coordinate system with a more abstract reference rectangle. Page sizes and zoom and so on will just be an application of the normalized

D21266: [WIP] Improve documentation of area classes

2019-06-02 Thread Albert Astals Cid
aacid added a comment. You really need to remove all the mentions of page you're adding, this is geometry that has nothing to do with pages. Yes in Okular in 99.99% of the cases it's used in conjunction with a page, but it is not about pages, it just so happen that most of the needs

D21266: [WIP] Improve documentation of area classes

2019-05-30 Thread David Hurka
davidhurka added a comment. Turns out that nothing is independent of page rotation, just discovered PagePrivate::rotateAt(Okular::Rotation), which transforms everything what is known to rotateAt(). Turns out that two facts turned out which let me wonder about the limited purpose of the

D21266: [WIP] Improve documentation of area classes

2019-05-30 Thread David Hurka
davidhurka added a comment. Turns out that the coordinate system of RegularAreaRect, as it is used by TextPage::textArea(TextSelection), is //not// independent of the page display. textArea() transforms the whole RegularAreaRect with the current totalRotation() of the Page. REPOSITORY

D21266: [WIP] Improve documentation of area classes

2019-05-20 Thread David Hurka
davidhurka updated this revision to Diff 58380. davidhurka added a comment. - NormalizedPoint: Revert some stuff and mention mouse click events REPOSITORY R223 Okular CHANGES SINCE LAST UPDATE https://phabricator.kde.org/D21266?vs=58231=58380 BRANCH

D21266: [WIP] Improve documentation of area classes

2019-05-20 Thread David Hurka
davidhurka added a comment. Should the section “Coordinate System” of NormalizedPoint mention the “Trimmed Margins” feature? To prevent that someone sloppily codes a feature, which draws something on the page and fails if Trim Margins is active. INLINE COMMENTS > aacid wrote in area.h:36 >

D21266: [WIP] Improve documentation of area classes

2019-05-19 Thread Albert Astals Cid
aacid added inline comments. INLINE COMMENTS > area.h:36 > * of a normalized point. Normalized means that the coordinates are > - * between 0 and 1 so that it is page size independent. > + * between 0 and 1, independent of the page size. > * i don't see why your version of the text is

D21266: [WIP] Improve documentation of area classes

2019-05-17 Thread David Hurka
davidhurka added a comment. This is part of my goal to understand how TextEntity reordering works. There will probably be more patches like this soon. I included some examples about how/where these classes are used. But why are there both RegularAreaRect (with its base classes) and

D21266: [WIP] Improve documentation of area classes

2019-05-17 Thread David Hurka
davidhurka created this revision. davidhurka added a reviewer: Okular. Herald added a project: Okular. Herald added a subscriber: okular-devel. davidhurka requested review of this revision. REVISION SUMMARY This shall improve the documentation of several area classes, including