Mercurial > hg > octave-nkf
changeset 12443:24b38afd6a45
fix plotyy bugs #31800, #32211
author | Konstantinos Poulios <logari81@googlemail.com> |
---|---|
date | Sun, 13 Feb 2011 21:37:18 +0100 |
parents | 278902427e87 |
children | 07e102029d2a |
files | src/ChangeLog src/gl-render.cc src/graphics.h.in |
diffstat | 3 files changed, 17 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,15 @@ +2011-02-13 Konstantinos Poulios <logari81@googlemail.com> + + Bugs #31800, #32211. + + * gl-render.cc (opengl_renderer::draw_axes_boxes): Draw only one + y-axis line when plotyy tag is present. + (opengl_renderer::draw_text): Remove superfluous calls of set_font + and set_color. + * graphics.h.in (class text::properties): Tag color with "u" + qualifier. + (text::properties::update_color): New function. + 2011-02-13 Konstantinos Poulios <logari81@googlemail.com> * graphics.h.in (axes::properties::update_boundingbox,
--- a/src/gl-render.cc +++ b/src/gl-render.cc @@ -849,6 +849,8 @@ double ypTickN = props.get_ypTickN (); double zpTickN = props.get_zpTickN (); + bool plotyy = (props.get_tag () == "plotyy"); + // Axes box set_linestyle ("-", true); @@ -878,7 +880,7 @@ glVertex3d (xpTick, yPlaneN, zpTick); glVertex3d (xpTick, yPlane, zpTick); - if (props.is_box ()) + if (props.is_box () && ! plotyy) { glVertex3d (xpTickN, yPlaneN, zpTick); glVertex3d (xpTickN, yPlane, zpTick); @@ -2398,9 +2400,6 @@ if (props.get_string ().empty ()) return; - set_font (props); - set_color (props.get_color_rgb ()); - const Matrix pos = xform.scale (props.get_data_position ()); const Matrix bbox = props.get_extent_matrix ();
--- a/src/graphics.h.in +++ b/src/graphics.h.in @@ -3644,7 +3644,7 @@ array_property position mu , Matrix (1, 3, 0.0) double_property rotation mu , 0 radio_property horizontalalignment mu , "{left}|center|right" - color_property color , color_values (0, 0, 0) + color_property color u , color_values (0, 0, 0) string_property fontname u , OCTAVE_DEFAULT_FONTNAME double_property fontsize u , 10 radio_property fontangle u , "{normal}|italic|oblique" @@ -3727,6 +3727,7 @@ void update_string (void) { request_autopos (); update_text_extent (); } void update_rotation (void) { update_text_extent (); } + void update_color (void) { update_text_extent (); } void update_fontname (void) { update_text_extent (); } void update_fontsize (void) { update_text_extent (); } void update_fontangle (void) { update_text_extent (); }