Ruler LPE does not consider drawing scale (page size / viewBox)

Bug #1460858 reported by Lucian on 2015-06-02
28
This bug affects 4 people
Affects Status Importance Assigned to Milestone
Inkscape
Medium
Jabiertxof

Bug Description

Observed in Inkscape-0.91+devel-r14188 - the ruler LPE creates marks which are significantly wider apart than the requested distance. I've tested with both inches and pixels and the result seems to be the same.

To test:

* Turn on the grid and snapping.
* Draw a horizontal line 400 pixels in length
* Apply the Ruler LPE with default settings (20px marks, major mark every 5 steps)

Expected result:

* A ruler should be drawn that lines up with the grid, there should be 21 marks including both ends

Actual result:

* The ruler is drawn with 7 marks at completely the wrong spacings.

This behaviour is reliable but sensitive to the state of the grid/units in the current document. It is possible to get the document to a place where the Ruler LPE will work correctly, but I'm not sure of the exact conditions under which this happens. I have not been able to reproduce the error in any way on 0.91, but it is not impossible that I've just been (un)lucky in that regard. It certainly seems easier to produce some form of broken behaviour in the trunk version than the correct behaviour, so hopefully this shouldn't be too hard to reproduce.

Tested on MacOS 10.10.3.

su_v (suv-lp) on 2015-06-02
tags: added: units
su_v (suv-lp) on 2015-06-02
summary: - Ruler LPE broken (very inaccurate)
+ Ruler LPE does not consider drawing scale (page size / viewBox)
su_v (suv-lp) wrote :

The internal handling of the units chosen in the 'Path Effects' dialog for the Ruler LPE do not take the drawing scale (ratio of 'width'/'height' to 'viewBox') into consideration. The observed mismatch can be avoided as well as reproduced both with Inkscape 0.91 r13725 and Inkscape 0.91+devel, depending on which template is used.

Result as expected:
- Inkscape 0.91 and default template ('px'-based drawing scale)
- Inkscape 0.91+devel and any 'px'-based template (e.g. 'default px')

Result not as expected:
- Inkscape 0.91 and any template which is not 'px'-based (e.g. 'default mm')
- Inkscape 0.91+devel and default template ('mm'-based drawing scale)

Changed in inkscape:
importance: Undecided → Medium
status: New → Confirmed
Hachmann (marenhachmann) wrote :

Workaround in 0.92.1 (as far as I could find out):

- if you're starting out with a mm based document, which already contains some data:
  - change display unit to px
  - change scale to 1
  - use transformation dialog to resize everything: select all, then use proportional resizing + value 100/0,26458 (%)

- if you can, start with a different template: New from template -> default px

Jabiertxof (jabiertxof) on 2017-04-19
Changed in inkscape:
assignee: nobody → Jabiertxof (jabiertxof)
Alex Farlie (afarlie) wrote :

https://bugs.launchpad.net/inkscape/+bug/1713477 would seem to be a duplicate of this.

Jabiertxof (jabiertxof) wrote :

This patch seems fix the bug. About the numering, I could do like meassure segments way, but need desirable exact types of numering

Alex Farlie (afarlie) wrote :

In respect of the "labelling" issue (i.e marking specific subdivisions in a specified manner), I will be putting my thoughts in a new bug/request.

Ok put here the link please!

On Wed, 2017-08-30 at 10:49 +0000, Alex Farlie wrote:
> In respect of the "labelling" issue (i.e marking specific
> subdivisions
> in a specified manner), I will be putting my thoughts in a new
> bug/request.
>

Alex Farlie (afarlie) wrote :

Enhancement request made here - https://bugs.launchpad.net/inkscape/+bug/1713982

Jabiertxof (jabiertxof) wrote :

Fixed in master in r.b715d8f04c

Changed in inkscape:
status: Confirmed → Fix Committed
Jabiertxof (jabiertxof) wrote :

Fixed in 0.92.x in r.c522dc6d40

Hachmann (marenhachmann) wrote :

Does anyone close the old reports?

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers