Qt status overhaul: add support for 'statuslines'
Condense the Qt status slightly, moving Alignment field from the Conditons line to the Characteristics line and the Time and Score fields from their own possibly blank line to the HP,&c,Gold line. That's for statuslines:2, which is the default. statuslines:3 restores the previous layout. I tried to make that become the default for Qt but it got messy fast and I gave up. I also tried to make changing 'statuslines' back and forth on the fly work but failed. I left the code in as #if DYNAMIC_STATUSLINES but that isn't defined anywhere. For the time being at least, 'statuslines' is config file or NETHACKOPTIONS only for Qt, not changeable via 'O' like for curses and tty. Change the option description for 'statuslines'. That depended upon whether curses was compiled in when it should depend on which interface is active. This moves the alternate info to Guidebook.
This commit is contained in:
@@ -1148,6 +1148,24 @@ void NetHackQtMainWindow::layout()
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef DYNAMIC_STATUSLINES // leave disabled; this doesn't work as intended
|
||||
// called when 'statuslines' changes from 2 to 3 or vice versa; simpler to
|
||||
// destroy and recreate the status window than to adjust existing fields
|
||||
void NetHackQtMainWindow::redoStatus()
|
||||
{
|
||||
NetHackQtStatusWindow *oldstatus = this->status;
|
||||
if (!oldstatus)
|
||||
return; // not ready yet?
|
||||
this->status = new NetHackQtStatusWindow;
|
||||
|
||||
if (!qt_compact_mode)
|
||||
hsplitter->replaceWidget(2, this->status->Widget());
|
||||
|
||||
delete oldstatus;
|
||||
ShowIfReady();
|
||||
}
|
||||
#endif
|
||||
|
||||
void NetHackQtMainWindow::resizePaperDoll(bool showdoll)
|
||||
{
|
||||
#ifdef ENHANCED_PAPERDOLL
|
||||
|
||||
Reference in New Issue
Block a user