Mercurial > hg > octave-lyh
view liboctave/operators/mx-ext.h @ 16502:45ae1038ee89
allow renaming of variables in workspace viewer
* main-window.h, main-window.cc
(main_window::handle_rename_variable_request): New function.
(main_window::construct_octave_qt_link): Connect
_workspace_model::rename_variable to
main_window::handle_rename_variable_request.
(main_window::rename_variable_callback): New function.
* octave-qt-link.h, octave-qt-link.cc
(octave_qt_link::do_set_workspace,
octave_qt_link::set_workspace_signal): New argument, top_level.
Change all uses.
* octave-link.h, octave-link.cc (octave_link::post_event):
Provide two-argument version.
(octave_link::set_workspace, octave_link::do_set_workspace):
New argument, top_level. Change all uses.
* workspace-model.h, workspace-model.cc (workspace_model::flags):
Conditionally add Qt::ItemIsEditable to flags.
(workspace_model::data): Also return value for column 0 if it is
editable.
(workspace_model::setData): Handle setting new values.
(workspace_model::_top_level): New data member.
(workspace_model::set_workspace): New argument, top_level.
(workspace_model::rename_variable): New signal.
* workspace-view.h, workspace-view.cc (variable_name_editor):
New class.
(workspace_view::var_name_editor): New data member.
(workspace_view::workspace_view): Initialize it. Set var_name_editor
as delegate for column 0.
(workspace_view::~workspace_view): Delete var_name_editor.
(workspace_view::item_double_clicked): Delete.
* symtab.h (symbol_table::rename, symbol_table::do_rename,
symbol_table::symbol_record::rename): New functions.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Fri, 12 Apr 2013 14:50:56 -0400 |
parents | 648dabbb4c6b |
children |
line wrap: on
line source
/* Copyright (C) 1994-2012 John W. Eaton This file is part of Octave. Octave is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version. Octave is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with Octave; see the file COPYING. If not, see <http://www.gnu.org/licenses/>. */ #if !defined (octave_mx_ext_h) #define octave_mx_ext_h 1 // Result of a AEP Balance operation. #include "dbleAEPBAL.h" #include "CmplxAEPBAL.h" // Result of a Determinant calculation. #include "DET.h" // Result of a Cholesky Factorization #include "dbleCHOL.h" #include "CmplxCHOL.h" #include "floatCHOL.h" #include "fCmplxCHOL.h" // Result of a Hessenberg Decomposition #include "dbleHESS.h" #include "CmplxHESS.h" // Result of a Schur Decomposition #include "dbleSCHUR.h" #include "CmplxSCHUR.h" #include "floatSCHUR.h" #include "fCmplxSCHUR.h" // Result of a Singular Value Decomposition. #include "dbleSVD.h" #include "CmplxSVD.h" #include "floatSVD.h" #include "fCmplxSVD.h" // Result of an Eigenvalue computation. #include "EIG.h" // Result of an LU decomposition. #include "dbleLU.h" #include "CmplxLU.h" #include "floatLU.h" #include "fCmplxLU.h" // Result of a QR decomposition. #include "dbleQR.h" #include "CmplxQR.h" #include "dbleQRP.h" #include "CmplxQRP.h" #endif