mirror of https://github.com/stella-emu/stella.git
Updated debugger size to resize down to 620 pixels high (from 690).
To do this, you lose access to the TIA 'RAM' display. For a future release, I'm going to evaluate whether this display is really necessary at all. This resize is for a request on the AtariAge 2.7.3 thread about running the debugger on an eeePC, which is 1024x600. For now, the closest I can get is 620. git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1685 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
This commit is contained in:
parent
15529746ea
commit
2fdb7401f2
|
@ -13,7 +13,7 @@
|
|||
// See the file "license" for information on usage and redistribution of
|
||||
// this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
//
|
||||
// $Id: Debugger.cxx,v 1.134 2009-01-20 21:01:28 stephena Exp $
|
||||
// $Id: Debugger.cxx,v 1.135 2009-03-26 19:46:05 stephena Exp $
|
||||
//============================================================================
|
||||
|
||||
#include "bspf.hxx"
|
||||
|
@ -107,7 +107,7 @@ Debugger::Debugger(OSystem* osystem)
|
|||
myReadTraps(NULL),
|
||||
myWriteTraps(NULL),
|
||||
myWidth(1030),
|
||||
myHeight(690)
|
||||
myHeight(620)
|
||||
{
|
||||
// Get the dialog size
|
||||
int w, h;
|
||||
|
@ -115,7 +115,7 @@ Debugger::Debugger(OSystem* osystem)
|
|||
myWidth = BSPF_max(w, 0);
|
||||
myHeight = BSPF_max(h, 0);
|
||||
myWidth = BSPF_max(myWidth, 1030u);
|
||||
myHeight = BSPF_max(myHeight, 690u);
|
||||
myHeight = BSPF_max(myHeight, 620u);
|
||||
myOSystem->settings().setSize("debuggerres", myWidth, myHeight);
|
||||
|
||||
// Init parser
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
// See the file "license" for information on usage and redistribution of
|
||||
// this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
//
|
||||
// $Id: TiaWidget.cxx,v 1.15 2009-01-01 18:13:35 stephena Exp $
|
||||
// $Id: TiaWidget.cxx,v 1.16 2009-03-26 19:46:05 stephena Exp $
|
||||
//
|
||||
// Based on code from ScummVM - Scumm Interpreter
|
||||
// Copyright (C) 2002-2004 The ScummVM project
|
||||
|
@ -43,56 +43,64 @@ TiaWidget::TiaWidget(GuiObject* boss, const GUI::Font& font,
|
|||
const int fontWidth = font.getMaxCharWidth(),
|
||||
fontHeight = font.getFontHeight(),
|
||||
lineHeight = font.getLineHeight();
|
||||
int xpos = 10, ypos = 25, lwidth = 4 * font.getMaxCharWidth();
|
||||
int xpos = 10, ypos = 10, lwidth = 4 * font.getMaxCharWidth();
|
||||
StaticTextWidget* t;
|
||||
|
||||
// Create a 16x1 grid holding byte values with labels
|
||||
myRamGrid = new DataGridWidget(boss, font, xpos + lwidth, ypos,
|
||||
16, 1, 2, 8, kBASE_16);
|
||||
myRamGrid->setEditable(false);
|
||||
myRamGrid->setTarget(this);
|
||||
myRamGrid->setID(kRamID);
|
||||
addFocusWidget(myRamGrid);
|
||||
|
||||
t = new StaticTextWidget(boss, font, xpos, ypos + 2,
|
||||
lwidth-2, fontHeight,
|
||||
"00:", kTextAlignLeft);
|
||||
for(int col = 0; col < 16; ++col)
|
||||
// Only do so if we have the vertical height
|
||||
// TODO - at some point, viewing RAM may be removed, as I don't know
|
||||
// how useful it really is
|
||||
if(h >= 400)
|
||||
{
|
||||
t = new StaticTextWidget(boss, font, xpos + col*myRamGrid->colWidth() + lwidth + 7,
|
||||
ypos - lineHeight,
|
||||
fontWidth, fontHeight,
|
||||
Debugger::to_hex_4(col),
|
||||
kTextAlignLeft);
|
||||
}
|
||||
ypos += lineHeight;
|
||||
myRamGrid = new DataGridWidget(boss, font, xpos + lwidth, ypos,
|
||||
16, 1, 2, 8, kBASE_16);
|
||||
myRamGrid->setEditable(false);
|
||||
myRamGrid->setTarget(this);
|
||||
myRamGrid->setID(kRamID);
|
||||
addFocusWidget(myRamGrid);
|
||||
|
||||
t = new StaticTextWidget(boss, font, xpos, ypos + 2,
|
||||
lwidth-2, fontHeight,
|
||||
"00:", kTextAlignLeft);
|
||||
for(int col = 0; col < 16; ++col)
|
||||
{
|
||||
t = new StaticTextWidget(boss, font, xpos + col*myRamGrid->colWidth() + lwidth + 7,
|
||||
ypos - lineHeight,
|
||||
fontWidth, fontHeight,
|
||||
Debugger::to_hex_4(col),
|
||||
kTextAlignLeft);
|
||||
}
|
||||
|
||||
xpos = 20; ypos += 2 * lineHeight;
|
||||
t = new StaticTextWidget(boss, font, xpos, ypos, 6*fontWidth, fontHeight,
|
||||
"Label:", kTextAlignLeft);
|
||||
xpos += 6*fontWidth + 5;
|
||||
myLabel = new EditTextWidget(boss, font, xpos, ypos-2, 15*fontWidth,
|
||||
lineHeight, "");
|
||||
myLabel->setEditable(false);
|
||||
xpos = 20; ypos += 2 * lineHeight;
|
||||
t = new StaticTextWidget(boss, font, xpos, ypos, 6*fontWidth, fontHeight,
|
||||
"Label:", kTextAlignLeft);
|
||||
xpos += 6*fontWidth + 5;
|
||||
myLabel = new EditTextWidget(boss, font, xpos, ypos-2, 15*fontWidth,
|
||||
lineHeight, "");
|
||||
myLabel->setEditable(false);
|
||||
|
||||
xpos += 15*fontWidth + 20;
|
||||
t = new StaticTextWidget(boss, font, xpos, ypos, 4*fontWidth, fontHeight,
|
||||
"Dec:", kTextAlignLeft);
|
||||
xpos += 4*fontWidth + 5;
|
||||
myDecValue = new EditTextWidget(boss, font, xpos, ypos-2, 4*fontWidth,
|
||||
lineHeight, "");
|
||||
myDecValue->setEditable(false);
|
||||
xpos += 15*fontWidth + 20;
|
||||
t = new StaticTextWidget(boss, font, xpos, ypos, 4*fontWidth, fontHeight,
|
||||
"Dec:", kTextAlignLeft);
|
||||
xpos += 4*fontWidth + 5;
|
||||
myDecValue = new EditTextWidget(boss, font, xpos, ypos-2, 4*fontWidth,
|
||||
lineHeight, "");
|
||||
myDecValue->setEditable(false);
|
||||
|
||||
xpos += 4*fontWidth + 20;
|
||||
t = new StaticTextWidget(boss, font, xpos, ypos, 4*fontWidth, fontHeight,
|
||||
"Bin:", kTextAlignLeft);
|
||||
xpos += 4*fontWidth + 5;
|
||||
myBinValue = new EditTextWidget(boss, font, xpos, ypos-2, 9*fontWidth,
|
||||
lineHeight, "");
|
||||
myBinValue->setEditable(false);
|
||||
xpos += 4*fontWidth + 20;
|
||||
t = new StaticTextWidget(boss, font, xpos, ypos, 4*fontWidth, fontHeight,
|
||||
"Bin:", kTextAlignLeft);
|
||||
xpos += 4*fontWidth + 5;
|
||||
myBinValue = new EditTextWidget(boss, font, xpos, ypos-2, 9*fontWidth,
|
||||
lineHeight, "");
|
||||
myBinValue->setEditable(false);
|
||||
ypos += lineHeight + 10;
|
||||
}
|
||||
|
||||
// Color registers
|
||||
const char* regNames[] = { "COLUP0:", "COLUP1:", "COLUPF:", "COLUBK:" };
|
||||
xpos = 10; ypos += 3*lineHeight;
|
||||
xpos = 10; ypos += lineHeight + 5;
|
||||
for(int row = 0; row < 4; ++row)
|
||||
{
|
||||
t = new StaticTextWidget(boss, font, xpos, ypos + row*lineHeight + 2,
|
||||
|
@ -228,7 +236,7 @@ TiaWidget::TiaWidget(GuiObject* boss, const GUI::Font& font,
|
|||
// P0 register info
|
||||
////////////////////////////
|
||||
// grP0
|
||||
xpos = 10; ypos = 13*lineHeight;
|
||||
xpos = 10; ypos = buttonY + 2*lineHeight;
|
||||
t = new StaticTextWidget(boss, font, xpos, ypos+2,
|
||||
7*fontWidth, fontHeight,
|
||||
"P0: GR:", kTextAlignLeft);
|
||||
|
@ -878,14 +886,17 @@ void TiaWidget::fillGrid()
|
|||
TiaState& oldstate = (TiaState&) tia.getOldState();
|
||||
|
||||
// TIA RAM
|
||||
alist.clear(); vlist.clear(); changed.clear();
|
||||
for(unsigned int i = 0; i < 16; i++)
|
||||
if(myRamGrid)
|
||||
{
|
||||
alist.push_back(i);
|
||||
vlist.push_back(state.ram[i]);
|
||||
changed.push_back(state.ram[i] != oldstate.ram[i]);
|
||||
alist.clear(); vlist.clear(); changed.clear();
|
||||
for(unsigned int i = 0; i < 16; i++)
|
||||
{
|
||||
alist.push_back(i);
|
||||
vlist.push_back(state.ram[i]);
|
||||
changed.push_back(state.ram[i] != oldstate.ram[i]);
|
||||
}
|
||||
myRamGrid->setList(alist, vlist, changed);
|
||||
}
|
||||
myRamGrid->setList(alist, vlist, changed);
|
||||
|
||||
// Color registers
|
||||
alist.clear(); vlist.clear(); changed.clear();
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
// See the file "license" for information on usage and redistribution of
|
||||
// this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
//
|
||||
// $Id: UIDialog.cxx,v 1.20 2009-01-05 22:05:35 stephena Exp $
|
||||
// $Id: UIDialog.cxx,v 1.21 2009-03-26 19:46:05 stephena Exp $
|
||||
//
|
||||
// Based on code from ScummVM - Scumm Interpreter
|
||||
// Copyright (C) 2002-2004 The ScummVM project
|
||||
|
@ -154,7 +154,7 @@ UIDialog::UIDialog(OSystem* osystem, DialogContainer* parent,
|
|||
myDebuggerHeightSlider = new SliderWidget(myTab, font, xpos, ypos, pwidth,
|
||||
lineHeight, "Debugger Height: ",
|
||||
lwidth, kDHeightChanged);
|
||||
myDebuggerHeightSlider->setMinValue(690);
|
||||
myDebuggerHeightSlider->setMinValue(620);
|
||||
myDebuggerHeightSlider->setMaxValue(1200);
|
||||
myDebuggerHeightSlider->setStepValue(10);
|
||||
wid.push_back(myDebuggerHeightSlider);
|
||||
|
@ -281,7 +281,7 @@ void UIDialog::loadConfig()
|
|||
// Debugger size
|
||||
instance().settings().getSize("debuggerres", w, h);
|
||||
w = BSPF_max(w, 1030);
|
||||
h = BSPF_max(h, 690);
|
||||
h = BSPF_max(h, 620);
|
||||
w = BSPF_min(w, 1920);
|
||||
h = BSPF_min(h, 1200);
|
||||
|
||||
|
|
Loading…
Reference in New Issue