bugGNU Octave - Bugs: bug #52169, gnuplot graphics toolkit tick...

 
 

bug #52169: gnuplot graphics toolkit tick color doesn't match axis color

Submitter:  Dan Sebald <sebald>
Submitted:  Wed 04 Oct 2017 07:30:58 PM UTC
   
 
Category:  Plotting with gnuplot Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Inaccurate Result
Status:  Confirmed Assigned to:  None
Originator Name:  Open/Closed:  * Open
Release:  * dev Operating System:  * Any
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Sun 15 Oct 2017 02:03:23 AM UTC, comment #5: 

Correct.  I searched old changesets I have for gnuplot on my computer and there's a sizable patch for adding the feature of controlling line color of ticks.  So, this was a gnuplot issue, not an Octave bug.  I was hoping to resurrect that patch and update it for gnuplot's current repository.  However, gnuplot is in a transition period at the moment, and I'm going to wait until things are stable there.  My estimate would be a month or two, at which point I'll post something here to make this bug report active once again.

Dan Sebald <sebald>
Sun 15 Oct 2017 01:54:30 AM UTC, comment #4: 

I went way back with hg bisect and I don't think this has ever worked.  I'm changing the group from Regression to just Innacurate Result.

Rik <rik5>
Group administrator
Fri 06 Oct 2017 08:54:03 PM UTC, comment #3: 

gnuplot chooses the tick color to match the border color.  That would be fine, if not for the fact that the plot can have different axes with different colors (and there is only a single border color).

Hmm, I'm starting to have flashbacks on this one.  This may be something a created a gnuplot patch for, but the patch never got implemented.  Let me investigate the gnuplot bug-report page.

Dan Sebald <sebald>
Fri 06 Oct 2017 08:23:12 PM UTC, comment #2: 

Since this is a regression, I've searched through all the patches I have here (I always copy my patches to a local subdirectory before posting).  The closest related patch (not sure it was ever pushed though) seems to be the following from djs2017mar10


diff --git a/scripts/plot/util/private/__gnuplot_draw_axes__.m b/scripts/plot/util/private/__gnuplot_draw_axes__.m
--- a/scripts/plot/util/private/__gnuplot_draw_axes__.m
+++ b/scripts/plot/util/private/__gnuplot_draw_axes__.m
@@ -2314,24 +2334,14 @@ function do_tics_1 (ticmode, tics, mtics
   endif
   colorspec = get_text_colorspec (color);
   fprintf (plot_stream, "set format %s \"%s\";\n", ax, fmt);
-  if (strcmp (ticmode, "manual"))
-    if (isempty (tics))
-      fprintf (plot_stream, "unset %stics;\nunset m%stics;\n", ax, ax);
-      return
-    endif
-    fprintf (plot_stream, "set %stics %s %s %s %s (", ax, tickdir,
-             ticklength, axispos, mirror);
-    fprintf (plot_stream, " %.15g,", tics(1:end-1));
-    fprintf (plot_stream, " %.15g) %s;\n", tics(end), fontspec);
+  if (strcmp (ticmode, "manual") && isempty (tics))
+    fprintf (plot_stream, "unset %stics;\nunset m%stics;\n", ax, ax);
+    return
   else
-    fprintf (plot_stream, "set %stics %s %s %s %s %s %s;\n", ax,
-             tickdir, ticklength, axispos, mirror, colorspec, fontspec);
-  endif
-  if (strcmp (labelmode, "manual"))
     k = 1;
     ntics = numel (tics);
     nlabels = numel (labels);
-    fprintf (plot_stream, "set %stics add %s %s %s %s (", ax,
+    fprintf (plot_stream, "set %stics %s %s %s %s (", ax,
              tickdir, ticklength, axispos, mirror);
     labels = strrep (labels, "%", "%%");
     for i = 1:ntics


That date would be after the July 2016 timeframe.  Notice how the re is one fprintf() removed that uses colorspec, but the one that is retained doesn't have the color spec.  Again, not sure if this was ever applied, or exactly what happened.  But this would be a good starting point for investigating where the issue might be.

I'll look at this and come up with a changeset.

Dan Sebald <sebald>
Thu 05 Oct 2017 11:55:50 PM UTC, comment #1: 

Confirmed.  And this is a regression.  This was reported earlier by me in bug #42947, but was also fixed back in July, 2016.

Rik <rik5>
Group administrator
Wed 04 Oct 2017 07:30:58 PM UTC, original submission:  

Try the following:


graphics_toolkit gnuplot
figure
plot(sin(0.03*pi*[0:50]), 'b');
set(gca, 'xcolor', 'b');
set(gca, 'ycolor', 'b');


The ticks are black when they should be blue.

Dan Sebald <sebald>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Digest:
   bug dependencies.

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by rik5 (Posted a comment)
  • -email is unavailable- added by sebald (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only group members can vote.

     

    Follow 4 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2017-10-15 rik5 Item GroupRegression Inaccurate Result
    2017-10-05 rik5 Item GroupIncorrect Result Regression
        StatusNone Confirmed
    2017-10-05 rik5 Dependencies- Depends on bugs #42947

    Back to the top

    Powered by Savane 3.13-4448.
    Corresponding source code