After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 400448 - ruler subdivision is wrong for inches
ruler subdivision is wrong for inches
Status: RESOLVED OBSOLETE
Product: GIMP
Classification: Other
Component: User Interface
git master
Other All
: Normal normal
: 2.10
Assigned To: GIMP Bugs
GIMP Bugs
: 775907 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2007-01-25 01:02 UTC by restrepo
Modified: 2018-05-24 12:08 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Ruler subdivisions for imperial metric (1.76 KB, patch)
2018-02-27 19:41 UTC, Lionel N.
committed Details | Review

Description restrepo 2007-01-25 01:02:16 UTC
Hi,

When showing INCHES, the ruler divisions are incorrect as it is divided using a decimal system.  Please remember that    

In INCHES, you need to show demarcations at 1/16, 1/8, 3/16, 1/4, 5/16, 3/8, 7/16, 1/2, ...   7/8, 15/16 and 1 inch.  As a reference, please go to http://www.thedollshousemall.com/paypal/044a%20%20%206%20inch%20ruler.jpg

Hope this allows for The GIMP to become even better than it already is.

Thanks for your contributions.

Jorge
Comment 1 Sven Neumann 2007-01-25 07:13:08 UTC
Well, sorry about that. But I don't think we are going to attempt changing the ruler widgets. We would rather remove all non-metric units.
Comment 2 Sven Neumann 2007-01-25 07:21:38 UTC
I closed this because I considered it too much work, but I guess we can get away with calling gtk_ruler_set_metric(). If that doesn't do what is being asked for here, we can still close the bug or reassign it to GTK+ (where it would be closed then).
Comment 3 Sven Neumann 2007-01-25 07:35:38 UTC
Seems to do what we want but we also have to change the ruler adjustments then. That code (gimp_display_shell_scale_setup()) could need some overhaul anyway. So if anyone wants to give it a try, feel free...
Comment 4 Michael Schumacher 2016-06-22 07:40:38 UTC
Given that GtkRuler has been deprecated and also removed from GTK+ 3, this is something to either try now or close as obsolete.
Comment 5 Michael Natterer 2016-06-22 07:54:06 UTC
We copied it to GIMP as GimpRuler a long time ago. We can fix this
in GIMP, even merge the fix to 2.8 if it still cleanly.
Just need a volunteer :)
Comment 6 Michael Schumacher 2016-12-09 22:21:27 UTC
*** Bug 775907 has been marked as a duplicate of this bug. ***
Comment 7 David Minerd 2016-12-10 18:27:46 UTC
Seriously don't mark this as obsolete. I'm certain every single GIMP user in the print industry is troubled by this. Please fix it or tell me how to recruit others who are willing.
Comment 8 Michael Natterer 2016-12-10 18:49:01 UTC
It wasn't marked as obsolete, comment 5 still applies.
Comment 9 Michael Schumacher 2016-12-10 20:03:11 UTC
As for recruiting, you could spread a link to the bug and to the place where the ticks are drawn (https://git.gnome.org/browse/gimp/tree/libgimpwidgets/gimpruler.c) among your peers, with "If you want imperial inch subdivisions in gimp, here's how you can help: ..." text alongside of it.

When trying to implement this, one will greatly benefit from knowing a bit of C and GTK+, and being able to build GIMP.

If someone needs help, our IRC channel - #gimp on irc.gimp.org - is the best place to get it.
Comment 10 Lena 2018-01-20 17:20:08 UTC
I too find this very troubling, since I always use the ruler for graph-measuring an image onto my canvas. It is impossible to do so with the Gimp ruler guidelines don't match my ruler. I wasn't even able to find a ruler with such increments to buy.
Comment 11 Michael Natterer 2018-01-20 17:25:58 UTC
Yeah this should really be finally done. Also, it's an actual bug
not an enhancement. And easily doable in 2.10.x is somebody wants
to fix it.
Comment 12 Jehan 2018-01-20 17:31:01 UTC
Hello,

the image from the original bug description is offline now. If I understand correctly, when in "inches" metrics, we don't want tenth divisions anymore, but 1/16, 1/8, 3/16, 1/4, is that it?

Just a question, is there none at all who also needs inches division as currently done? I am wondering if there should be 2 versions of the inch ruler.

Adding newcomers keyword because I don't think that would be hard to do.
Comment 13 Michael Natterer 2018-01-24 22:26:24 UTC
Google helped: https://i.stack.imgur.com/uyWo0.jpg
Comment 14 Michael Natterer 2018-02-12 11:27:04 UTC
As this patch shows, it's easily doable. We just need to collect
subdivision rules for different units (inches, yards, whatnot), and
add the right RulerMetric structs.

commit fd37737fe4f3a7e84c1e0aff8ace24253250aa27
Author: Michael Natterer <mitch@gimp.org>
Date:   Mon Feb 12 12:20:32 2018 +0100

    Bug 400448 - ruler subdivision is wrong for inches
    
    This commit changes nothing, but contains disabled proof-of-concept
    code to use different ruler subdivisions depending on the ruler's
    unit.

 libgimpwidgets/gimpruler.c | 91 +++++++++++++++++++++++++++++-----------------
 1 file changed, 57 insertions(+), 34 deletions(-)
Comment 15 Lionel N. 2018-02-27 19:41:11 UTC
Created attachment 369058 [details] [review]
Ruler subdivisions for imperial metric

Hello,

I wrote a small patch based on Michael comment 14.

As I am not accustomed with imperial metrics, some further enhancements may be required, especially for feet and yards unit. Just have to update ruler_metric_feet and ruler_metric_yards.

Maybe someone more knowledgeable can give some insight ?
Comment 16 Michael Natterer 2018-02-27 22:29:00 UTC
Thanks Lionel, I pushed the patch, but changed the unit check to
be a check on the unit's factor. Also kept the code disabled for
double checking:

commit 827d747fae65c0e347beb70bdc0655ce09555765
Author: Lionel N <lionel@libreart.info>
Date:   Tue Feb 27 20:28:50 2018 +0100

    Bug 400448 - ruler subdivision is wrong for inches
    
    Add ruler subdivisions for feet and yards, the code is still disabled.

 libgimpwidgets/gimpruler.c | 32 ++++++++++++++++++++++++++++++--
 1 file changed, 30 insertions(+), 2 deletions(-)
Comment 17 Jehan 2018-02-28 00:44:16 UTC
Review of attachment 369058 [details] [review]:

Pushed by Mitch.
Comment 18 GNOME Infrastructure Team 2018-05-24 12:08:09 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to GNOME's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/gimp/issues/230.