Mercurial > hg > octave-nkf
changeset 20741:dcfbf4c1c3c8
eliminate trailing whitespace and tabs from sources
* Canvas.cc, Canvas.h, Figure.cc, gl-render.h,
graphics.cc, ov-fcn-handle.cc, ov-java.cc, Range.cc, CmplxCHOL.cc,
dbleCHOL.cc, floatCHOL.cc: Eliminate trailing whitespace and tabs used
for indentation.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Thu, 01 Oct 2015 12:50:00 -0400 |
parents | 17e507df10e3 |
children | 2480bbcd1333 |
files | libgui/graphics/Canvas.cc libgui/graphics/Canvas.h libgui/graphics/Figure.cc libinterp/corefcn/gl-render.h libinterp/corefcn/graphics.cc libinterp/octave-value/ov-fcn-handle.cc libinterp/octave-value/ov-java.cc liboctave/array/Range.cc liboctave/numeric/CmplxCHOL.cc liboctave/numeric/dbleCHOL.cc liboctave/numeric/floatCHOL.cc |
diffstat | 11 files changed, 34 insertions(+), 37 deletions(-) [+] |
line wrap: on
line diff
--- a/libgui/graphics/Canvas.cc +++ b/libgui/graphics/Canvas.cc @@ -268,7 +268,6 @@ ap.set_zgrid (state); redraw (true); - } } } @@ -371,8 +370,8 @@ return zm.contents ("Motion").string_value (); } -void -Canvas::select_object (graphics_object obj, QMouseEvent* event, +void +Canvas::select_object (graphics_object obj, QMouseEvent* event, graphics_object ¤tObj, graphics_object &axesObj, bool axes_only) { @@ -407,21 +406,20 @@ for (QList<graphics_object>::ConstIterator it = axesList.begin (); it != axesList.end (); ++it) { - const axes::properties& ap = + const axes::properties& ap = dynamic_cast<const axes::properties&> ((*it).get_properties ()); ColumnVector p0 = ap.pixel2coord (pt.x (), pt.y ()); Matrix xlim = ap.get_xlim ().matrix_value (); Matrix ylim = ap.get_ylim ().matrix_value (); - if (xlim(0) < p0(0) && xlim(1) > p0(0) + if (xlim(0) < p0(0) && xlim(1) > p0(0) && ylim(0) < p0(1) && ylim(1) > p0(1)) { axesObj = *it; return; } } - } else if (! currentObj) { @@ -523,8 +521,8 @@ } } - // Update mouse coordinates in the figure window status bar - graphics_object figObj = + // Update mouse coordinates in the figure window status bar + graphics_object figObj = gh_manager::get_object (m_handle).get_ancestor ("figure"); if (figObj.valid_object ()) @@ -534,16 +532,16 @@ if (axesObj.valid_object ()) { - // FIXME: should we use signal/slot mechanism instead of + // FIXME: should we use signal/slot mechanism instead of // directly calling parent fig methods - Figure* fig = + Figure* fig = dynamic_cast<Figure*> (Backend::toolkitObject (figObj)); axes::properties& ap = Utils::properties<axes> (axesObj); if (fig) fig->updateStatusBar (ap.pixel2coord (event->x (), event->y ())); } - } + } } void @@ -591,7 +589,7 @@ { graphics_object figObj (obj.get_ancestor ("figure")); graphics_object currentObj, axesObj; - + select_object (obj, event, currentObj, axesObj); if (axesObj) @@ -633,7 +631,7 @@ if (currentObj.get ("buttondownfcn").is_empty ()) { - graphics_object parentObj = + graphics_object parentObj = gh_manager::get_object (currentObj.get_parent ()); if (parentObj.valid_object () && parentObj.isa ("hggroup"))
--- a/libgui/graphics/Canvas.h +++ b/libgui/graphics/Canvas.h @@ -108,8 +108,8 @@ const graphics_object& obj); void annotation_callback (const octave_value_list& args); - void select_object (graphics_object obj, QMouseEvent* event, - graphics_object ¤tObj, graphics_object &axesObj, + void select_object (graphics_object obj, QMouseEvent* event, + graphics_object ¤tObj, graphics_object &axesObj, bool axes_only = false); private:
--- a/libgui/graphics/Figure.cc +++ b/libgui/graphics/Figure.cc @@ -129,14 +129,14 @@ { m_container = new Container (win); win->setCentralWidget (m_container); - + figure::properties& fp = properties<figure> (); // Enable mouse tracking m_container->setMouseTracking (true); foreach (QWidget* w, m_container->findChildren<QWidget*> ()) { w->setMouseTracking (true); } - + // Status bar m_statusBar = win->statusBar (); int boffset = 0; @@ -151,7 +151,7 @@ { toffset += m_figureToolBar->sizeHint ().height (); boffset += m_statusBar->sizeHint ().height (); - } + } else { m_figureToolBar->hide (); @@ -437,7 +437,7 @@ if (! m_menuBar->isHidden ()) toffset += m_menuBar->sizeHint ().height () + 1; - + if (! m_statusBar->isHidden ()) boffset += m_statusBar->sizeHint ().height () + 1;
--- a/libinterp/corefcn/gl-render.h +++ b/libinterp/corefcn/gl-render.h @@ -108,7 +108,7 @@ double z1, double z2); virtual void set_clipping (bool on); virtual void set_font (const base_properties& props); - virtual void set_interpreter (const caseless_str interp) + virtual void set_interpreter (const caseless_str interp) { interpreter = interp; }
--- a/libinterp/corefcn/graphics.cc +++ b/libinterp/corefcn/graphics.cc @@ -2289,7 +2289,7 @@ for (octave_idx_type p = 0; p < m.nfields (); p++) { // FIXME: Would it be better to extract all the keys at once rather than - // repeatedly call keys() inside a for loop? + // repeatedly call keys() inside a for loop? caseless_str pname = m.keys ()[p]; octave_value val = octave_value (m.contents (pname).elem (m.numel () - 1)); @@ -3091,7 +3091,7 @@ base_properties::mark_modified (void) { // Mark existing object as modified - __modified__ = "on"; + __modified__ = "on"; // Attempt to mark parent object as modified if it exists graphics_object parent_go = gh_manager::get_object (get_parent ()); if (parent_go)
--- a/libinterp/octave-value/ov-fcn-handle.cc +++ b/libinterp/octave-value/ov-fcn-handle.cc @@ -1872,7 +1872,7 @@ eval_string (nm, true, parse_status); if (parse_status == 0) - retval = anon_fcn_handle; + retval = anon_fcn_handle; } else retval = make_fcn_handle (nm, nargin != 2);
--- a/libinterp/octave-value/ov-java.cc +++ b/libinterp/octave-value/ov-java.cc @@ -1847,12 +1847,12 @@ } // FIXME: Need routines to actually save/load java objects through Serialize. -// See bug #42112. +// See bug #42112. bool octave_java::save_ascii (std::ostream& /* os */) { - warning ("save: unable to save java objects, skipping"); + warning ("save: unable to save java objects, skipping"); return true; } @@ -1867,7 +1867,7 @@ bool octave_java::save_binary (std::ostream& /* os */, bool& /* save_as_floats */) { - warning ("save: unable to save java objects, skipping"); + warning ("save: unable to save java objects, skipping"); return true; }
--- a/liboctave/array/Range.cc +++ b/liboctave/array/Range.cc @@ -54,7 +54,7 @@ if (rng_numel > 0 && cache.numel () == 0) { cache.resize (1, rng_numel); - + // The first element must always be *exactly* the base. // E.g, -0 would otherwise become +0 in the loop (-0 + 0*increment). cache(0) = rng_base;
--- a/liboctave/numeric/CmplxCHOL.cc +++ b/liboctave/numeric/CmplxCHOL.cc @@ -120,7 +120,7 @@ { for (octave_idx_type i = 0; i < j; i++) chol_mat.xelem (i, j) = 0.0; - for (octave_idx_type i = j; i < n; i++) + for (octave_idx_type i = j; i < n; i++) chol_mat.xelem (i, j) = a (i, j); } }
--- a/liboctave/numeric/dbleCHOL.cc +++ b/liboctave/numeric/dbleCHOL.cc @@ -120,7 +120,7 @@ { for (octave_idx_type i = 0; i < j; i++) chol_mat.xelem (i, j) = 0.0; - for (octave_idx_type i = j; i < n; i++) + for (octave_idx_type i = j; i < n; i++) chol_mat.xelem (i, j) = a (i, j); } } @@ -161,14 +161,13 @@ F77_XFCN (dpocon, DPOCON, (F77_CONST_CHAR_ARG2 ("U", 1), n, h, n, anorm, xrcond, pz, piz, dpocon_info F77_CHAR_ARG_LEN (1))); - } + } else { F77_XFCN (dpocon, DPOCON, (F77_CONST_CHAR_ARG2 ("L", 1), n, h, n, anorm, xrcond, pz, piz, dpocon_info F77_CHAR_ARG_LEN (1))); - } - + } if (dpocon_info != 0) info = -1;
--- a/liboctave/numeric/floatCHOL.cc +++ b/liboctave/numeric/floatCHOL.cc @@ -136,13 +136,13 @@ { F77_XFCN (spotrf, SPOTRF, (F77_CONST_CHAR_ARG2 ("U", 1), n, h, n, info - F77_CHAR_ARG_LEN (1))); + F77_CHAR_ARG_LEN (1))); } else { F77_XFCN (spotrf, SPOTRF, (F77_CONST_CHAR_ARG2 ("L", 1), n, h, n, info - F77_CHAR_ARG_LEN (1))); + F77_CHAR_ARG_LEN (1))); } xrcond = 0.0; @@ -161,13 +161,13 @@ { F77_XFCN (spocon, SPOCON, (F77_CONST_CHAR_ARG2 ("U", 1), n, h, n, anorm, xrcond, pz, piz, spocon_info - F77_CHAR_ARG_LEN (1))); + F77_CHAR_ARG_LEN (1))); } else { F77_XFCN (spocon, SPOCON, (F77_CONST_CHAR_ARG2 ("L", 1), n, h, n, anorm, xrcond, pz, piz, spocon_info - F77_CHAR_ARG_LEN (1))); + F77_CHAR_ARG_LEN (1))); } @@ -218,7 +218,7 @@ { for (octave_idx_type j = 0; j < r_nc; j++) for (octave_idx_type i = j+1; i < r_nr; i++) - tmp.xelem (i, j) = tmp.xelem (j, i); + tmp.xelem (i, j) = tmp.xelem (j, i); } else {