aboutsummaryrefslogtreecommitdiffstats
path: root/ui/qt/column_preferences_frame.cpp
diff options
context:
space:
mode:
authorStig Bjørlykke <stig@bjorlykke.org>2017-07-16 23:51:37 +0200
committerAnders Broman <a.broman58@gmail.com>2017-07-17 04:15:08 +0000
commit30f7014dfc4de64d6d4fb937fc75856e21210dcb (patch)
tree7d5ed47b70e5e810d2873e97b10e706b490ea144 /ui/qt/column_preferences_frame.cpp
parent4dd48721ee633fd2db3534ad2e43c00847dce42f (diff)
Qt: Expand column preferences text edit fields to column width
When editing a custom column the text edit field should fill the column. Change-Id: I5505238d13c4dbe26e9dbc4ae60fd602120f9596 Reviewed-on: https://code.wireshark.org/review/22657 Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
Diffstat (limited to 'ui/qt/column_preferences_frame.cpp')
-rw-r--r--ui/qt/column_preferences_frame.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/ui/qt/column_preferences_frame.cpp b/ui/qt/column_preferences_frame.cpp
index 9e6cf9d51e..e7fd1d6cdd 100644
--- a/ui/qt/column_preferences_frame.cpp
+++ b/ui/qt/column_preferences_frame.cpp
@@ -256,6 +256,7 @@ void ColumnPreferencesFrame::on_columnTreeWidget_itemActivated(QTreeWidgetItem *
{
if (!item || cur_line_edit_ || cur_combo_box_) return;
+ QTreeWidget *ctw = ui->columnTreeWidget;
QWidget *editor = NULL;
cur_column_ = column;
saved_combo_idx_ = item->data(type_col_, Qt::UserRole).toInt();
@@ -290,6 +291,7 @@ void ColumnPreferencesFrame::on_columnTreeWidget_itemActivated(QTreeWidgetItem *
connect(field_filter_edit, SIGNAL(textChanged(QString)),
field_filter_edit, SLOT(checkCustomColumn(QString)));
connect(field_filter_edit, SIGNAL(editingFinished()), this, SLOT(customFieldsEditingFinished()));
+ field_filter_edit->setFixedWidth(ctw->columnWidth(custom_fields_col_));
editor = cur_line_edit_ = field_filter_edit;
//Save off the current column type in case it needs to be restored
@@ -307,6 +309,7 @@ void ColumnPreferencesFrame::on_columnTreeWidget_itemActivated(QTreeWidgetItem *
connect(syntax_edit, SIGNAL(textChanged(QString)),
syntax_edit, SLOT(checkInteger(QString)));
connect(syntax_edit, SIGNAL(editingFinished()), this, SLOT(customOccurrenceEditingFinished()));
+ syntax_edit->setFixedWidth(ctw->columnWidth(custom_occurrence_col_));
editor = cur_line_edit_ = syntax_edit;
//Save off the current column type in case it needs to be restored