26 #if defined (HAVE_CONFIG_H)
34 #include <QHBoxLayout>
35 #include <QHeaderView>
38 #include <QModelIndexList>
39 #include <QMouseEvent>
41 #include <QStringList>
42 #include <QTableWidget>
43 #include <QTableWidgetItem>
65 #define AUTO_HEIGHT (tp.get_fontsize () * 2 - 1)
69 int w = t->verticalHeader ()->width () + 4;
70 for (
int i = 0; i < t->columnCount (); i++)
71 w += t->columnWidth (i);
72 int h = t->horizontalHeader ()->height () + 4;
73 for (
int i = 0; i < t->rowCount (); i++)
74 h += t->rowHeight (i);
78 #define FORMATNUMBER(type) \
79 static QString formatNumber (type d, \
86 return QString::number (d, 'g', precision); \
87 else if (d <= pow (10, precision - 1) && d > pow (10, 1 - precision)) \
88 return QString::number (d, 'f', precision); \
90 return QString::number (d, 'e', precision); \
92 else if (format == 'F') \
94 int exponent = floor (log10 (d) / 3) * 3; \
95 d *= pow (10, -exponent); \
96 return QString::number (d, 'f', precision) + "e" + \
97 (exponent < 0 ? "-" : "+") + \
98 QString ("%1").arg (abs (exponent), 3, 10, QChar ('0')); \
100 else if (format == 'E') \
102 int exponent = floor (log10 (d) / 3) * 3; \
103 d *= pow (10, -exponent); \
104 return QString::number (d, \
106 precision - floor (log10 (d)) - 1) + \
107 "e" + (exponent < 0 ? "-" : "+") + \
108 QString ("%1").arg (abs (exponent), 3, 10, QChar ('0')); \
111 return QString::number (d, format, precision); \
125 #define FORMAT_VALUE_EXCEPT_RAT(f,l) \
126 if (format == "numeric" || format == "short") \
127 text = formatNumber (value, 'n', f); \
128 else if (format == "short f" || format == "shortf") \
129 text = formatNumber (value, 'f', f); \
130 else if (format == "short e" || format == "shorte") \
131 text = formatNumber (value, 'e', f); \
132 else if (format == "short eng" || format == "shorteng") \
133 text = formatNumber (value, 'F', f); \
134 else if (format == "short g" || format == "shortg") \
135 text = formatNumber (value, 'g', f + 1); \
136 else if (format == "long") \
137 text = formatNumber (value, 'n', l); \
138 else if (format == "long f" || format == "longf") \
139 text = formatNumber (value, 'f', l); \
140 else if (format == "long e" || format == "longe") \
141 text = formatNumber (value, 'e', l); \
142 else if (format == "long eng" || format == "longeng") \
143 text = formatNumber (value, 'E', l); \
144 else if (format == "long g" || format == "longg") \
145 text = formatNumber (value, 'g', l + 1); \
146 else if (format == "bank") \
147 text = QString::number (value, 'f', 2); \
148 else if (format == "+") \
150 text = Utils::fromStdString ("+"); \
151 else if (value < 0) \
152 text = Utils::fromStdString ("-"); \
154 text = Utils::fromStdString ("");
156 #define FORMAT_VALUE(f,l) \
157 FORMAT_VALUE_EXCEPT_RAT(f,l) \
158 else if (format == "rat") \
159 text = Utils::fromStdString (rational_approx (double (value), 0)); \
162 text = formatNumber (value, 'n', f); \
163 flag = Qt::AlignLeft ; \
166 #define FORMAT_UINT_VALUE() \
167 text = QString::number (value); \
168 if (format == "char" || format == "popup") \
169 flag = Qt::AlignLeft; \
170 else if (format == "+") \
173 text = Utils::fromStdString ("+"); \
175 text = Utils::fromStdString (""); \
178 #define FORMAT_INT_VALUE() \
179 text = QString::number (value); \
180 if (format == "char" || format == "popup") \
181 flag = Qt::AlignLeft ; \
182 else if (format == "+") \
185 text = Utils::fromStdString ("+"); \
186 else if (value < 0) \
187 text = Utils::fromStdString ("-"); \
189 text = Utils::fromStdString (""); \
192 static std::pair<Qt::AlignmentFlag, QString>
195 Qt::AlignmentFlag flag = Qt::AlignRight;
200 flag = Qt::AlignLeft ;
214 else if (
format ==
"long")
222 else if (
format ==
"bank")
223 text = QString::number (c.real (),
'f', 2);
228 else if (c.real () < 0)
236 else if (
format ==
"numeric")
237 text = QString::number (c.real (),
'g', 5) +
" + "
238 + QString::number (c.imag (),
'g', 5) +
"i";
241 text = QString::number (c.real (),
'g', 5) +
" + "
242 + QString::number (c.imag (),
'g', 5) +
"i";
243 flag = Qt::AlignLeft ;
302 flag = Qt::AlignLeft ;
307 flag = Qt::AlignLeft ;
314 std::stringstream warn_string;
315 warn_string <<
"Unknown conversion for datatype " << val.
class_name ()
318 warning (
"%s", warn_string.str ().c_str ());
323 return std::make_pair (flag,
text);
327 #undef FORMAT_VALUE_EXCEPT_RAT
328 #undef FORMAT_UINT_VALUE
329 #undef FORMAT_INT_VALUE
332 bool enabled =
false)
334 QTableWidgetItem *
retval =
new QTableWidgetItem ();
335 std::pair<Qt::AlignmentFlag, QString> flag_and_text =
337 retval->setTextAlignment (flag_and_text.first);
338 retval->setText (flag_and_text.second);
341 retval->setFlags (
retval->flags () | Qt::ItemIsEditable);
343 retval->setFlags (
retval->flags () & ~Qt::ItemIsEditable);
357 #define SCANF_AND_CONVERT(name,ctype,format) \
358 else if (old_value.is_ ## name ## _type ()) \
362 const std::string cxx_str = ov.string_value (); \
363 const char *c_str = cxx_str.c_str (); \
364 int error = sscanf (c_str, format, &val, &n); \
365 if (error != 1 || c_str[n]) \
369 retval = octave_value ( octave_ ## name (val)); \
383 #undef SCANF_AND_CONVERT
412 QCheckBox *checkBox =
new QCheckBox ();
413 QHBoxLayout *layout =
new QHBoxLayout (
retval);
414 layout->addWidget (checkBox);
415 layout->setAlignment (Qt::AlignCenter);
416 layout->setContentsMargins (0, 0, 0, 0);
417 retval->setLayout (layout);
420 checkBox->setCheckState (Qt::Checked);
422 checkBox->setCheckState (Qt::Unchecked);
424 checkBox->setAttribute (Qt::WA_TransparentForMouseEvents,
true);
425 checkBox->setFocusPolicy (Qt::NoFocus);
426 checkBox->setProperty (
"Enabled", QVariant (enabled));
442 return new Table (oct_qobj, interp, go,
new QTableWidget (container));
450 :
Object (oct_qobj, interp, go, tableWidget), m_tableWidget (tableWidget),
451 m_curData (), m_blockUpdates (false)
453 qObject ()->setObjectName (
"UItable");
465 m_tableWidget->setSelectionBehavior (QAbstractItemView::SelectItems);
493 if (! (properties<uitable> ().get_cellselectioncallback ().isempty ()))
495 QModelIndexList modelIndexList =
497 int length = modelIndexList.size ();
499 for (
int i = 0; i <
length; i++)
501 indices(i, 0) = modelIndexList.value (i).
row () + 1;
502 indices(i, 1) = modelIndexList.value (i).
column () + 1;
505 eventData.
setfield (
"Indices", indices);
509 cellSelectionCallbackEventObject);
516 QCheckBox *checkBox =
nullptr;
518 = qobject_cast<QWidget *> (
m_tableWidget->cellWidget (row, col));
519 if (widget && ! widget->children ().isEmpty ())
522 = qobject_cast<QHBoxLayout *> (widget->children ().first ());
524 if (layout && layout->count () > 0)
525 checkBox = qobject_cast<QCheckBox *> (layout->itemAt (0)-> widget ());
528 if (checkBox && checkBox->property (
"Enabled").toBool ())
541 if (!(properties<uitable> ().get_celleditcallback ().isempty ()))
544 indices(0, 0) = row + 1;
545 indices(0, 1) = col + 1;
548 eventData.
setfield (
"Indices", indices);
549 eventData.
setfield (
"PreviousData", old_value);
550 eventData.
setfield (
"NewData", new_value);
551 eventData.
setfield (
"EditData", edit_data);
558 cellEditCallbackEventObject);
560 else if (
error.string_value ().length () > 0)
579 QComboBox *comboBox = qobject_cast<QComboBox *> (sender ());
580 int row = comboBox->property (
"row").toInt ();
581 int col = comboBox->property (
"col").toInt ();
591 if (cell(row, col).is_string ())
593 cell(row, col) = edit_data;
666 octave_value (
"Table data is not editable at this location.");
677 comboBox->setCurrentIndex (-1);
678 comboBox->setEditable (
true);
679 comboBox->setEditText (comboBox->property (
"original_value").toString ());
680 comboBox->lineEdit ()->setReadOnly (
true);
696 bool new_value = ! checkBox->isChecked ();
703 if (row < matrix.
rows () && col < matrix.
columns ())
705 bool old_value = matrix(row, col);
706 matrix(row, col) = new_value;
707 checkBox->setChecked (new_value);
708 if (new_value != old_value)
729 octave_value (
"Table data is not editable at this location."));
737 if (cell(row, col).islogical ())
739 bool old_value = cell(row, col).bool_value ();
741 checkBox->setChecked (new_value);
742 if (new_value != old_value)
763 octave_value (
"Cannot convert logical edit to other type."));
773 octave_value (
"Table data is not editable at this location."));
785 octave_value (
"Cannot convert logical edit to other type."));
794 octave_value (
"Table data is not editable at this location."));
814 int row = item->row ();
815 int col = item->column ();
834 new_value = edit_data;
838 std::pair<Qt::AlignmentFlag, QString> flag_and_text =
840 item->setTextAlignment (flag_and_text.first);
841 item->setText (flag_and_text.second);
847 cell(row, col) = new_value;
870 octave_value (
"Table data is not editable at this location.");
885 update (uitable::properties::ID_POSITION);
895 case uitable::properties::ID_BACKGROUNDCOLOR:
896 case uitable::properties::ID_FOREGROUNDCOLOR:
900 case uitable::properties::ID_COLUMNNAME:
905 case uitable::properties::ID_COLUMNWIDTH:
909 case uitable::properties::ID_COLUMNEDITABLE:
910 case uitable::properties::ID_COLUMNFORMAT:
911 case uitable::properties::ID_DATA:
922 case uitable::properties::ID_ENABLE:
926 case uitable::properties::ID_KEYPRESSFCN:
930 case uitable::properties::ID_KEYRELEASEFCN:
934 case uitable::properties::ID_FONTNAME:
935 case uitable::properties::ID_FONTSIZE:
936 case uitable::properties::ID_FONTWEIGHT:
937 case uitable::properties::ID_FONTANGLE:
948 case uitable::properties::ID_POSITION:
959 case uitable::properties::ID_REARRANGEABLECOLUMNS:
963 case uitable::properties::ID_ROWNAME:
967 case uitable::properties::ID_ROWSTRIPING:
971 case uitable::properties::ID_TOOLTIPSTRING:
975 case base_properties::ID_VISIBLE:
999 l << QString::number (i + 1);
1007 else if (columnname.
isempty ())
1014 else if (columnname.
iscell ())
1033 if (data.
rows () > 1 && data.
cols () > 1)
1037 l << QString::number (data(j));
1051 l << QString::number (matrix_value(i));
1060 l.replaceInStrings (
"|",
"\n");
1067 for (
int col = oldColumnCount; col < l.length (); col++)
1097 (qobject_cast<QAbstractItemView *> (
m_tableWidget))->sizeHintForColumn (i);
1098 int header_size =
m_tableWidget->horizontalHeader ()->sectionSizeHint (i);
1100 if (column_size > header_size)
1101 header_size = column_size;
1104 else if (columnwidth.
iscell ())
1116 (qobject_cast<QAbstractItemView *> (
m_tableWidget))->sizeHintForColumn (i);
1117 int header_size =
m_tableWidget->horizontalHeader ()->sectionSizeHint (i);
1119 if (column_size > header_size)
1120 header_size = column_size;
1132 (qobject_cast<QAbstractItemView *> (
m_tableWidget))->sizeHintForColumn (i);
1133 int header_size =
m_tableWidget->horizontalHeader ()->sectionSizeHint (i);
1135 if (column_size > header_size)
1136 header_size = column_size;
1160 bool editable =
false;
1177 if (ov_columnformat.
iscell ())
1186 else if (! format_value.
isempty () && format_value.
iscell ())
1200 octave_value data = properties<uitable> ().get_data ();
1218 octave_value data = properties<uitable> ().get_data ();
1230 std::string
format =
"",
bool enabled =
false)
1238 m_tableWidget->cellWidget (row, col)->setProperty (
"row", QVariant (row));
1239 m_tableWidget->cellWidget (row, col)->setProperty (
"col", QVariant (col));
1241 else if (
format ==
"popup" && enabled)
1248 octave_value format_value = tp.get_columnformat ().cell_value ().xelem (col);
1250 QComboBox *comboBox =
new QComboBox ();
1251 comboBox->setProperty (
"row", QVariant (row));
1252 comboBox->setProperty (
"col", QVariant (col));
1255 for (
int k = 0; k < format_value.
numel (); k++)
1260 comboBox->addItem (popup_item);
1262 if (popup_item == string_value)
1265 comboBox->setCurrentIndex (index);
1269 comboBox->setEditable (
true);
1270 comboBox->setEditText (string_value);
1271 comboBox->lineEdit ()->setReadOnly (
true);
1274 comboBox->setProperty (
"original_value", QVariant (string_value));
1276 comboBox->installEventFilter (
this);
1278 connect (comboBox, SIGNAL(currentIndexChanged (
const QString&)),
1313 bool enabled = tp.is_enable ();
1316 bool rearrangeableColumns = tp.is_rearrangeablecolumns ();
1320 ? QAbstractItemView::ExtendedSelection
1321 : QAbstractItemView::NoSelection);
1324 #if defined (HAVE_QT4)
1325 m_tableWidget->horizontalHeader ()->setMovable (enabled && rearrangeableColumns);
1326 #elif defined (HAVE_QT5)
1327 m_tableWidget->horizontalHeader ()->setSectionsMovable (enabled && rearrangeableColumns);
1329 m_tableWidget->horizontalHeader ()->setDragEnabled (enabled && rearrangeableColumns);
1330 m_tableWidget->horizontalHeader ()->setDragDropMode (QAbstractItemView::InternalMove);
1333 for (
int col = 0; col <
m_tableWidget->columnCount (); col++)
1338 if (QTableWidgetItem *item =
m_tableWidget->item (row, col))
1340 Qt::ItemFlags flags = item->flags ();
1341 if (enabled && editable)
1342 item->setFlags (flags | Qt::ItemIsEditable);
1344 item->setFlags (flags & ~Qt::ItemIsEditable);
1348 QCheckBox *checkBox =
nullptr;
1349 if (widget && ! widget->children ().isEmpty ())
1352 = qobject_cast<QHBoxLayout *> (widget->children ().first ());
1354 if (layout && layout->count () > 0)
1355 checkBox = qobject_cast<QCheckBox *> (layout->itemAt (0)-> widget ());
1359 widget->setProperty (
"Enabled", QVariant (enabled & editable));
1362 widget->setAttribute (Qt::WA_TransparentForMouseEvents,
1363 !(editable & enabled));
1365 widget->setFocusPolicy (Qt::NoFocus);
1378 extent(0, 2) = s.width ();
1379 extent(0, 3) = s.height () ;
1390 p.setColor (QPalette::Text,
1392 p.setColor (QPalette::Base,
1394 p.setColor (QPalette::AlternateBase,
1397 m_tableWidget->setAlternatingRowColors (tp.is_rowstriping ());
1411 bool visible =
true;
1415 l << QString::number (i + 1);
1429 else if (rowname.
iscell ())
1448 if (data.
rows () > 1 && data.
cols () > 1)
1452 l << QString::number (data(j));
1466 l << QString::number (matrix_value(i));
1481 for (
int col = 0; col <
m_tableWidget->columnCount (); col++)
1486 for (
int row = oldRowCount; row < l.length (); row++)
1504 bool rearrangeableColumns = tp.is_rearrangeablecolumns ();
1505 bool enabled = tp.is_enable ();
1507 #if defined (HAVE_QT4)
1508 m_tableWidget->horizontalHeader ()->setMovable (enabled && rearrangeableColumns);
1509 #elif defined (HAVE_QT5)
1510 m_tableWidget->horizontalHeader ()->setSectionsMovable (enabled && rearrangeableColumns);
1512 m_tableWidget->horizontalHeader ()->setDragEnabled (enabled && rearrangeableColumns);
1513 m_tableWidget->horizontalHeader ()->setDragDropMode (QAbstractItemView::InternalMove);
1522 if (qobject_cast<QTableWidget *> (watched))
1524 switch (xevent->type ())
1526 case QEvent::Resize:
1534 Utils::properties<uitable> (go);
1535 if (tp.fontunits_is (
"normalized"))
1541 case QEvent::MouseButtonPress:
1545 QMouseEvent *
m =
dynamic_cast<QMouseEvent *
> (xevent);
1548 Utils::properties<uitable> (go);
1551 if (
m->button () != Qt::LeftButton || ! tp.is_enable ())
1559 "windowbuttondownfcn");
1562 if (
m->button () == Qt::RightButton)
1574 case QEvent::KeyPress:
1576 QKeyEvent *k =
dynamic_cast<QKeyEvent *
> (xevent);
1585 keyData.
getfield (
"Character"),
false);
1594 QCheckBox *checkBox =
nullptr;
1597 = qobject_cast<QWidget *> (
m_tableWidget->cellWidget (row, col));
1599 if (widget && ! widget->children ().isEmpty ())
1602 = qobject_cast<QHBoxLayout *> (widget->children ().first ());
1604 if (layout && layout->count () > 0)
1605 checkBox = qobject_cast<QCheckBox *> (layout->itemAt (0)-> widget ());
1608 if (checkBox && checkBox->property (
"Enabled").toBool ())
1612 = qobject_cast<QComboBox *> (
m_tableWidget->cellWidget (row, col));
1615 comboBox->showPopup ();
1619 case Qt::Key_Return:
1622 if (k->modifiers () == Qt::NoModifier)
1634 else if (k->modifiers () == Qt::ShiftModifier)
1659 case QEvent::KeyRelease:
1665 QKeyEvent *k =
dynamic_cast<QKeyEvent *
> (xevent);
1671 keyData.
getfield (
"Character"),
false);
1681 else if (qobject_cast<QComboBox *> (watched))
1683 switch (xevent->type ())
1685 case QEvent::MouseButtonPress:
1689 QMouseEvent *
m =
dynamic_cast<QMouseEvent *
> (xevent);
1694 if (
m->button () != Qt::LeftButton || ! tp.is_enable ())
1702 "windowbuttondownfcn");
1705 if (
m->button () == Qt::RightButton)
1713 QComboBox *comboBox_0 = qobject_cast<QComboBox *> (watched);
1716 for (
int col = 0; col <
m_tableWidget->columnCount (); col++)
1718 QComboBox *comboBox_1
1719 = qobject_cast<QComboBox *> (
m_tableWidget->cellWidget (row, col));
1721 if (comboBox_0 == comboBox_1)
#define FORMAT_INT_VALUE()
#define SCANF_AND_CONVERT(name, ctype, format)
#define FORMAT_VALUE(f, l)
#define FORMAT_UINT_VALUE()
#define FORMATNUMBER(type)
octave_idx_type columns(void) const
octave_idx_type numel(void) const
Number of elements in the array.
octave_idx_type cols(void) const
octave_idx_type rows(void) const
RowVector row(octave_idx_type i) const
ColumnVector column(octave_idx_type i) const
static void executeAt(octave::interpreter &interp, const base_properties &props, const QPoint &pt)
graphics_object object(void) const
base_properties & properties(void)
virtual Container * innerContainer(void)=0
octave::interpreter & m_interpreter
static Object * parentObject(octave::interpreter &interp, const graphics_object &go)
void gh_callback_event(const graphics_handle &h, const std::string &name)
void gh_set_event(const graphics_handle &h, const std::string &name, const octave_value &value)
virtual QObject * qObject(void)
void updateDataColumn(int col)
bool m_keyPressHandlerDefined
void updateColumnname(void)
QWidget * checkBoxForLogical(octave_value cal, bool enabled)
void sendCellEditCallback(int row, int col, octave_value old_value, octave_value new_value, octave_value edit_data, octave_value error)
std::string columnformat(int column)
bool eventFilter(QObject *watched, QEvent *event)
void comboBoxCurrentIndexChanged(const QString &value)
void itemChanged(QTableWidgetItem *item)
Table(octave::base_qobject &oct_qobj, octave::interpreter &interp, const graphics_object &go, QTableWidget *tableWidget)
bool columneditable(int column)
bool m_keyReleaseHandlerDefined
void itemSelectionChanged(void)
void updateRearrangeableColumns(void)
void cellClicked(int row, int col)
void updateColumnwidth(void)
static Table * create(octave::base_qobject &oct_qobj, octave::interpreter &interp, const graphics_object &go)
QTableWidget * m_tableWidget
void checkBoxClicked(int row, int col, QCheckBox *checkBox)
octave::mutex graphics_lock(void)
graphics_object get_ancestor(const std::string &type) const
graphics_handle get_handle(void) const
bool valid_object(void) const
Base class for Octave interfaces that use Qt.
gh_manager & get_gh_manager(void)
void setfield(const std::string &key, const octave_value &val)
octave_value getfield(const std::string &key) const
uint64_t uint64_value(bool req_int=false, bool frc_str_conv=false) const
bool bool_value(bool warn=false) const
bool fast_elem_insert(octave_idx_type n, const octave_value &x)
Assign the n-th element, aka 'val(n) = x'.
int int_value(bool req_int=false, bool frc_str_conv=false) const
bool is_uint16_type(void) const
bool is_bool_scalar(void) const
int64_t int64_value(bool req_int=false, bool frc_str_conv=false) const
short int short_value(bool req_int=false, bool frc_str_conv=false) const
Complex complex_value(bool frc_str_conv=false) const
bool is_int8_type(void) const
octave_idx_type rows(void) const
bool isnumeric(void) const
octave_idx_type numel(void) const
unsigned short int ushort_value(bool req_int=false, bool frc_str_conv=false) const
bool is_string(void) const
bool isinteger(void) const
bool is_double_type(void) const
Cell cell_value(void) const
std::string class_name(void) const
bool is_uint32_type(void) const
octave_idx_type columns(void) const
bool is_int64_type(void) const
float float_value(bool frc_str_conv=false) const
unsigned long int ulong_value(bool req_int=false, bool frc_str_conv=false) const
boolMatrix bool_matrix_value(bool warn=false) const
octave_value fast_elem_extract(octave_idx_type n) const
Extract the n-th element, aka 'val(n)'.
std::string string_value(bool force=false) const
bool is_matrix_type(void) const
bool is_int32_type(void) const
bool is_uint64_type(void) const
bool is_int16_type(void) const
long int long_value(bool req_int=false, bool frc_str_conv=false) const
bool is_single_type(void) const
bool is_uint8_type(void) const
Matrix matrix_value(bool frc_str_conv=false) const
bool iscomplex(void) const
double double_value(bool frc_str_conv=false) const
unsigned int uint_value(bool req_int=false, bool frc_str_conv=false) const
bool islogical(void) const
Matrix get_boundingbox(bool internal=false, const Matrix &parent_pix_size=Matrix()) const
void warning(const char *fmt,...)
void error(const char *fmt,...)
std::complex< double > w(std::complex< double > z, double relerr=0)
QColor fromRgb(const Matrix &rgb)
std::string figureSelectionType(QMouseEvent *event, bool isDoubleClick)
template QFont computeFont< uitable >(const uitable::properties &props, int height)
octave_scalar_map makeKeyEventStruct(QKeyEvent *event)
Matrix figureCurrentPoint(const graphics_object &fig, QMouseEvent *event)
QString fromStdString(const std::string &s)
std::string toStdString(const QString &s)
static QTableWidgetItem * itemFor(octave_value val, std::string format="", bool enabled=false)
static QString formatNumber(double d, char format='f', int precision=4)
static const int AUTO_WIDTH
static QString formatComplex(Complex c, char format='f', int precision=4)
static QSize realQSizeForTable(QTableWidget *t)
static std::pair< Qt::AlignmentFlag, QString > qStringValueFor(octave_value val, std::string format="")
static octave_value attempt_type_conversion(const octave_value &ov, const octave_value &old_value)
OCTAVE_API Complex str2double(const std::string &str_arg)
size_t format(std::ostream &os, const char *fmt,...)
std::complex< double > Complex
std::complex< float > FloatComplex
std::string rational_approx(T val, int len)
return octave_value(v1.char_array_value() . concat(v2.char_array_value(), ra_idx),((a1.is_sq_string()||a2.is_sq_string()) ? '\'' :'"'))
octave_value::octave_value(const Array< char > &chm, char type) return retval