GNOME Bugzilla – Bug 700599
axis scale: cannot set manual scale, if it matches auto scale
Last modified: 2015-04-13 12:56:14 UTC
Created attachment 244652 [details] spreadsheet to exhibit axis bugs Recipe: 1) Draw a graph. Allow the axes to be automatically scaled. 2) On the Scale tab, unclick the Automatic scale. Click "Apply". 3) Re-examine the properties. Find that automatic scaling has mysteriously and very unhelpfully been turned back on. Workaround: -- Uncheck "automatic" and change the scale from (say) 0.6 to 0.60001 Click "Apply". -- This seems to work. However, this can lead to other problems, as described elsewhere; see Bug 700598
I see the point, but I'm wondering why you need to change the value to manual if you don't actually change the value. For now the solution is not to add a small increment to the value, but you change it to anything else and then back to the auto value. Once you have changed the value, it becomes really manual. On the technical side of the issue, I'm not sure this can be fixed without an API break.
Jean, an obvious use case is if you set up a cart and expect to change the data it uses afterwards. In this case it may be desirable to fix the axis range to a specific value even if it happens to be the current value.
Just click on the entry and validate, this will really set the value and make it manual. There is actually no need to change the value twice as I wrote in comment #2.
Jean, doesn't your 'workaround' of comment #3 really provide a way of implementing this without an API break?
What I describe in comment #3 actually already works. The issue is that it should work even without validating the entry.
Jean, my thought was that appending gtk_widget_activate (GTK_WIDGET (closure->editor)); to cb_enable_dim in gog-axis.c should have the same effect as "Just click on the entry and validate". It doesn't seem to work though.
*** Bug 747619 has been marked as a duplicate of this bug. ***
Created attachment 301366 [details] [review] Proposed patch Plase test this patch.
(In reply to Jean Bréfort from comment #8) > Plase test this patch. I tested the patch. Yes, it makes the symptoms go away. I did only an empirical operational test. I don't understand the root cause well enough to review the code itself.
Works for me.
Created attachment 301391 [details] Date axis sample With this sample, unclicking automatic for the X axis changes from a date formatted value to a plain number.
Ah, I see, I did not check for the format. Things are then more involved and might need an API break.
Maybe, but in the meantime let's commit this patch. Even with that glitch, this is far better than without.
Review of attachment 301366 [details] [review]: Patch commited.
Fixed the date issue. This problem has been fixed in our software repository. The fix will go into the next software release. Once that release is available, you may want to check for a software upgrade provided by your Linux distribution.