Mercurial > octave-nkf
comparison libinterp/corefcn/graphics.cc @ 19895:19755f4fc851
maint: Cleanup C++ code to follow Octave coding conventions.
Try to wrap long lines to < 80 characters.
Use GNU style and don't indent first brace of function definition.
"case" statement is aligned flush left with brace of switch stmt.
Remove trailing '\' line continuation from the end of #define macros.
Use 2 spaces for indent.
* files-dock-widget.cc, history-dock-widget.cc, main-window.cc, octave-cmd.cc,
octave-dock-widget.cc, octave-gui.cc, resource-manager.cc, settings-dialog.cc,
shortcut-manager.cc, welcome-wizard.cc, workspace-view.cc, cellfun.cc, data.cc,
debug.cc, debug.h, dirfns.cc, error.h, file-io.cc, gl-render.cc, gl-render.h,
gl2ps-renderer.h, graphics.cc, graphics.in.h, help.cc, input.cc, load-path.cc,
load-path.h, lookup.cc, lu.cc, oct-stream.cc, octave-default-image.h,
ordschur.cc, pr-output.cc, qz.cc, strfns.cc, symtab.cc, symtab.h, sysdep.cc,
variables.cc, zfstream.h, __fltk_uigetfile__.cc, __init_fltk__.cc,
__magick_read__.cc, __osmesa_print__.cc, audiodevinfo.cc, ov-classdef.cc,
ov-classdef.h, ov-fcn.h, ov-float.cc, ov-flt-complex.cc, ov-java.cc,
ov-range.cc, ov-re-mat.cc, ov-usr-fcn.h, ov.cc, op-int.h, options-usage.h,
pt-eval.cc, Array-C.cc, Array-fC.cc, Array.cc, Array.h, PermMatrix.cc,
Sparse.cc, chMatrix.h, dSparse.cc, dim-vector.h, bsxfun-decl.h, bsxfun-defs.cc,
oct-norm.cc, Sparse-op-defs.h, oct-inttypes.cc, oct-inttypes.h, main.in.cc,
mkoctfile.in.cc: Cleanup C++ code to follow Octave coding conventions.
author | Rik <rik@octave.org> |
---|---|
date | Wed, 25 Feb 2015 11:55:49 -0800 |
parents | 426525fb3b9f |
children | 17d647821d61 |
comparison
equal
deleted
inserted
replaced
19894:e8ccfc5d892b | 19895:19755f4fc851 |
---|---|
1345 | 1345 |
1346 xok = false; | 1346 xok = false; |
1347 | 1347 |
1348 // check dimensional size constraints until a match is found | 1348 // check dimensional size constraints until a match is found |
1349 for (std::list<dim_vector>::const_iterator it = size_constraints.begin (); | 1349 for (std::list<dim_vector>::const_iterator it = size_constraints.begin (); |
1350 ! xok && it != size_constraints.end ();++it) | 1350 ! xok && it != size_constraints.end (); ++it) |
1351 { | 1351 { |
1352 dim_vector itdims = (*it); | 1352 dim_vector itdims = (*it); |
1353 | 1353 |
1354 if (itdims.length () == vlen) | 1354 if (itdims.length () == vlen) |
1355 { | 1355 { |
3173 | 3173 |
3174 void | 3174 void |
3175 base_graphics_object::build_user_defaults_map (property_list::pval_map_type &def, const std::string go_name) const | 3175 base_graphics_object::build_user_defaults_map (property_list::pval_map_type &def, const std::string go_name) const |
3176 { | 3176 { |
3177 property_list local_defaults = get_defaults_list (); | 3177 property_list local_defaults = get_defaults_list (); |
3178 property_list::plist_map_const_iterator p = | 3178 property_list::plist_map_const_iterator p = |
3179 local_defaults.find (go_name); | 3179 local_defaults.find (go_name); |
3180 | 3180 |
3181 if (p != local_defaults.end ()) | 3181 if (p != local_defaults.end ()) |
3182 { | 3182 { |
3183 property_list::pval_map_type pval = p->second; | 3183 property_list::pval_map_type pval = p->second; |
3184 for (property_list::pval_map_const_iterator q = pval.begin (); | 3184 for (property_list::pval_map_const_iterator q = pval.begin (); |
3185 q != pval.end (); q++) | 3185 q != pval.end (); q++) |
3197 | 3197 |
3198 } | 3198 } |
3199 | 3199 |
3200 void | 3200 void |
3201 base_graphics_object::reset_default_properties (void) | 3201 base_graphics_object::reset_default_properties (void) |
3202 { | 3202 { |
3203 if (valid_object ()) | 3203 if (valid_object ()) |
3204 { | 3204 { |
3205 property_list::pval_map_type factory_pval = | 3205 property_list::pval_map_type factory_pval = |
3206 gh_manager::get_object (0).get_factory_defaults_list () | 3206 gh_manager::get_object (0).get_factory_defaults_list () |
3207 .find (type ())->second; | 3207 .find (type ())->second; |
3208 | 3208 |
3209 xreset_default_properties (get_handle (), factory_pval); | 3209 xreset_default_properties (get_handle (), factory_pval); |
3210 } | 3210 } |
3211 } | 3211 } |
3212 | 3212 |
3213 std::string | 3213 std::string |
3214 base_graphics_object::values_as_string (void) | 3214 base_graphics_object::values_as_string (void) |
3215 { | 3215 { |
3216 std::string retval; | 3216 std::string retval; |