get and set splitter position
Solved
General and Desktop
-
Use sizes() to get it and setSizes() to set it.
-
@Chris-Kawa
it only giveing the size of the splitter .i want to set the position .
-
@saber
Hi
You set position by changing size(s).
as @Chris-Kawa says -
@Chris-Kawa
sorry for my ignorance .
i understand now.but what is the vreable to save that by qsettings?
uasilly i save and get my settings by this way.QSize SettingsManage::setSplitterPos(QSize mode) { return setSpecificValue("CoreFM", "Splitter-Pos", mode); } QSize SettingsManage::getSplitterPos() { return getSpecificValue("CoreFM", "Splitter-Pos").toSize(); }
is that be qlist?
-
@saber
About ?
http://doc.qt.io/qt-5/qsplitter.html#restoreStateit just allow you to store or load the layout of the splitter