Port xconfig to Qt5 - Add horizontal scrollbar, and scroll per pixel.
Signed-off-by: Boris Barbulovski <bbarbulovski@gmail.com>
Signed-off-by: Thiago Macieira <thiago.macieira@intel.com>
Signed-off-by: Michal Marek <mmarek@suse.com>
diff --git a/scripts/kconfig/qconf.cc b/scripts/kconfig/qconf.cc
index 9edb9c5..10fe15d 100644
--- a/scripts/kconfig/qconf.cc
+++ b/scripts/kconfig/qconf.cc
@@ -318,6 +318,9 @@
setSortingEnabled(false);
setRootIsDecorated(true);
+ setVerticalScrollMode(ScrollPerPixel);
+ setHorizontalScrollMode(ScrollPerPixel);
+
setHeaderLabels(QStringList() << _("Option") << _("Name") << "N" << "M" << "Y" << _("Value"));
connect(this, SIGNAL(itemSelectionChanged(void)),
@@ -450,11 +453,13 @@
updateMenuList(item, rootEntry);
update();
+ resizeColumnToContents(0);
return;
}
update:
updateMenuList(this, rootEntry);
update();
+ resizeColumnToContents(0);
}
void ConfigList::setValue(ConfigItem* item, tristate val)