Bug 436214 - Feature Request: Measure distances (and areas?)
Summary: Feature Request: Measure distances (and areas?)
Status: REPORTED
Alias: None
Product: okular
Classification: Applications
Component: general (show other bugs)
Version: 24.08.1
Platform: unspecified Linux
: NOR wishlist
Target Milestone: ---
Assignee: Okular developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-04-26 13:23 UTC by Ph. Marek
Modified: 2024-09-22 20:57 UTC (History)
6 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ph. Marek 2021-04-26 13:23:37 UTC
It would be great if there was some tool to measure distances (in points, mm, cm, dpi) and perhaps areas in an PDF.

I'd imagine zooming in as much as necessary, then choosing the measurement tool, and dragging a line (resp. a rectangle) on the screen; either the status bar or a hovering popup could show the distance in some choosable units (one or multiple).


Thanks a lot!
Comment 1 Don 2023-09-27 15:45:11 UTC
additional to just being able to measure sheet distance allowing for a scaling option on the reported distance would make Okular incredibly useful for the Architecture, Engineering, and Construction (AEC) market. We typically need to scale dimensions from drawings and right now the opensource options for this are extremely limited to work arounds with either InkScape or GIMP.
Comment 2 vderuido 2024-09-11 21:05:52 UTC
Hi!

I totally support this initiative. There is really a lack for this type of functionality in Linux.

Unfortunately, I don't have the coding skills to do this myself, but I have used software with this functionality at my job and I can give some feedback on how the user experience usually is (to hopefully help to someone actually make it true :) ).

Usually there are 2 types of ways for performing measurements into a document:

## Option 1 ("Easy")
- The user selects the "calibration button"
- The user picks two points in the document
- A popup window appears asking the user for introducing the distance of those 2 points (in a drop-down  menu you can select the unit)  
- Okular extracts the distance between 2 points and "calibrates" the document accordingly (using the dimensions of the page of the document)
- The user now can select the "measure" button where two new points can be selected and obtain the desired the distance.

## Option 2 (Probably more tricky)
- In the "calibrate" option there are a set of default scales the user can pick from (1:50, 1:100, etc. specifying the units, of course)
- Knowing the dimensions of page, the calibration is set up and the user can measure as above.

Once is developed the functionality can be extended in the future using with extra calculations such as simple areas (squares, circles), the perimeter of a polyline/polygone, etc.

I'm aware that this is easier said than done, but I think quite some people could benefit from this!
Comment 3 Francisco 2024-09-12 10:45:46 UTC
Additionally, PDF documents can have Measurament data for the real-world 
scale transformation. Check section 12.9 of the PDF standard:


https://opensource.adobe.com/dc-acrobat-sdk-docs/pdfstandards/PDF32000_2008.pdf