From ee15739e7e4b2477d80c6d38968b934f0d787f2b Mon Sep 17 00:00:00 2001 From: atlante45 Date: Tue, 25 Jun 2013 01:28:31 +0200 Subject: [PATCH] few fixes on the job 19368 --- interface/src/Application.cpp | 17 +++++++++-------- interface/src/Swatch.cpp | 2 +- 2 files changed, 10 insertions(+), 9 deletions(-) diff --git a/interface/src/Application.cpp b/interface/src/Application.cpp index a8cc750cae..970344e41f 100644 --- a/interface/src/Application.cpp +++ b/interface/src/Application.cpp @@ -1359,7 +1359,7 @@ void Application::initMenu() { QMenu* renderMenu = menuBar->addMenu("Render"); (_renderVoxels = renderMenu->addAction("Voxels"))->setCheckable(true); _renderVoxels->setChecked(true); - _renderVoxels->setShortcut(Qt::Key_V); + _renderVoxels->setShortcut(Qt::CTRL | Qt::Key_V); (_renderVoxelTextures = renderMenu->addAction("Voxel Textures"))->setCheckable(true); (_renderStarsOn = renderMenu->addAction("Stars"))->setCheckable(true); _renderStarsOn->setChecked(true); @@ -1395,19 +1395,19 @@ void Application::initMenu() { _voxelModeActions->setExclusive(false); // exclusivity implies one is always checked (_addVoxelMode = voxelMenu->addAction( - "Add Voxel Mode", this, SLOT(updateVoxelModeActions()), Qt::CTRL | Qt::Key_V))->setCheckable(true); + "Add Voxel Mode", this, SLOT(updateVoxelModeActions()), Qt::Key_V))->setCheckable(true); _voxelModeActions->addAction(_addVoxelMode); (_deleteVoxelMode = voxelMenu->addAction( - "Delete Voxel Mode", this, SLOT(updateVoxelModeActions()), Qt::CTRL | Qt::Key_R))->setCheckable(true); + "Delete Voxel Mode", this, SLOT(updateVoxelModeActions()), Qt::Key_R))->setCheckable(true); _voxelModeActions->addAction(_deleteVoxelMode); (_colorVoxelMode = voxelMenu->addAction( - "Color Voxel Mode", this, SLOT(updateVoxelModeActions()), Qt::CTRL | Qt::Key_B))->setCheckable(true); + "Color Voxel Mode", this, SLOT(updateVoxelModeActions()), Qt::Key_B))->setCheckable(true); _voxelModeActions->addAction(_colorVoxelMode); (_selectVoxelMode = voxelMenu->addAction( - "Select Voxel Mode", this, SLOT(updateVoxelModeActions()), Qt::CTRL | Qt::Key_S))->setCheckable(true); + "Select Voxel Mode", this, SLOT(updateVoxelModeActions()), Qt::Key_O))->setCheckable(true); _voxelModeActions->addAction(_selectVoxelMode); (_eyedropperMode = voxelMenu->addAction( - "Get Color Mode", this, SLOT(updateVoxelModeActions()), Qt::CTRL | Qt::Key_G))->setCheckable(true); + "Get Color Mode", this, SLOT(updateVoxelModeActions()), Qt::Key_G))->setCheckable(true); _voxelModeActions->addAction(_eyedropperMode); voxelMenu->addAction("Decrease Voxel Size", this, SLOT(decreaseVoxelSize()), QKeySequence::ZoomOut); @@ -1552,6 +1552,7 @@ void Application::init() { _palette.addTool(_swatch); _palette.addAction(_colorVoxelMode, 0, 2); _palette.addAction(_eyedropperMode, 0, 3); + _palette.addAction(_selectVoxelMode, 0, 4); } const float MAX_AVATAR_EDIT_VELOCITY = 1.0f; @@ -2297,8 +2298,8 @@ void Application::displayOverlay() { const char* line1("Assign this color to a swatch"); const char* line2("by choosing a key from 1 to 8."); double step(0.05f); - int left(_glWidget->width()/100.0f); - int top(_glWidget->height()*7.0f/10.0f); + int left((_glWidget->width() - 320)/2); + int top(_glWidget->height()/40.0f); double margin(10.0f); glBegin(GL_POLYGON); diff --git a/interface/src/Swatch.cpp b/interface/src/Swatch.cpp index 572046d5e1..5989a2e512 100644 --- a/interface/src/Swatch.cpp +++ b/interface/src/Swatch.cpp @@ -86,7 +86,7 @@ void Swatch::render(int screenWidth, int screenHeight) { glVertex2f(_margin, i*(_height - _margin) + _margin); glEnd(); - if (_colors[i].lightness() < 100) { + if (_colors[i].lightness() < 50) { glBegin(GL_LINES); glColor3f(1.0f, 1.0f, 1.0f); glVertex2f(_margin, (i + 1)*(_height - _margin));