Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTon Roosendaal <ton@blender.org>2004-07-28 17:21:27 +0400
committerTon Roosendaal <ton@blender.org>2004-07-28 17:21:27 +0400
commit76616c266e4df87ccce9cbede3730e5e417b3dd1 (patch)
treee99ef3db432772f1aae10dc181071627ae930968 /source/blender/src/drawview.c
parent4f9cd88087b2696855b63b6d50c53691da3393ab (diff)
Added new selection outline as option in View->View Properties panel. And
while working there added 3d cursor there as well. I admit it isn't the best location ever, but let's do the threaded discussions after 2.34 is out. :)
Diffstat (limited to 'source/blender/src/drawview.c')
-rw-r--r--source/blender/src/drawview.c42
1 files changed, 27 insertions, 15 deletions
diff --git a/source/blender/src/drawview.c b/source/blender/src/drawview.c
index 7ed0444a0cf..5d69c6a328e 100644
--- a/source/blender/src/drawview.c
+++ b/source/blender/src/drawview.c
@@ -1610,6 +1610,7 @@ static void view3d_panel_properties(short cntrl) // VIEW3D_HANDLER_SETTINGS
{
uiBlock *block;
View3D *vd;
+ float *curs;
vd= G.vd;
@@ -1618,24 +1619,35 @@ static void view3d_panel_properties(short cntrl) // VIEW3D_HANDLER_SETTINGS
uiSetPanelHandler(VIEW3D_HANDLER_PROPERTIES); // for close and esc
if(uiNewPanel(curarea, block, "View Properties", "View3d", 340, 10, 318, 204)==0) return;
- uiDefBut(block, LABEL, 1, "Grid:", 0, 162, 150, 19, NULL, 0.0, 0.0, 0, 0, "");
-
- uiDefButF(block, NUM, REDRAWVIEW3D, "Spacing:", 0, 140, 140, 19, &vd->grid, 0.001, 100.0, 10, 0, "Set the distance between grid lines");
- uiDefButS(block, NUM, REDRAWVIEW3D, "Lines:", 150, 140, 140, 19, &vd->gridlines, 0.0, 100.0, 100, 0, "Set the number of grid lines");
+ uiDefBut(block, LABEL, 1, "Grid:", 10, 180, 150, 19, NULL, 0.0, 0.0, 0, 0, "");
+ uiBlockBeginAlign(block);
+ uiDefButF(block, NUM, REDRAWVIEW3D, "Spacing:", 10, 160, 140, 19, &vd->grid, 0.001, 100.0, 10, 0, "Set the distance between grid lines");
+ uiDefButS(block, NUM, REDRAWVIEW3D, "Lines:", 10, 140, 140, 19, &vd->gridlines, 0.0, 100.0, 100, 0, "Set the number of grid lines");
+ uiBlockBeginAlign(block);
+ uiDefButBitS(block, TOG, V3D_SHOW_FLOOR, REDRAWVIEW3D, "Grid Floor",160, 160, 150, 19, &vd->gridflag, 0, 0, 0, 0, "Show the grid floor in free camera mode");
+ uiDefButBitS(block, TOG, V3D_SHOW_X, REDRAWVIEW3D, "X Axis", 160, 140, 50, 19, &vd->gridflag, 0, 0, 0, 0, "Show the X Axis line");
+ uiDefButBitS(block, TOG, V3D_SHOW_Y, REDRAWVIEW3D, "Y Axis", 210, 140, 50, 19, &vd->gridflag, 0, 0, 0, 0, "Show the Y Axis line");
+ uiDefButBitS(block, TOG, V3D_SHOW_Z, REDRAWVIEW3D, "Z Axis", 260, 140, 50, 19, &vd->gridflag, 0, 0, 0, 0, "Show the Z Axis line");
+ uiBlockEndAlign(block);
- uiDefBut(block, LABEL, 1, "3D Grid:", 0, 110, 150, 19, NULL, 0.0, 0.0, 0, 0, "");
+ uiDefBut(block, LABEL, 1, "View Camera:", 10, 110, 140, 19, NULL, 0.0, 0.0, 0, 0, "");
- uiDefButBitS(block, TOG, V3D_SHOW_FLOOR, REDRAWVIEW3D, "Grid Floor", 0, 88, 90, 19, &vd->gridflag, 0, 0, 0, 0, "Show the grid floor in free camera mode");
- uiDefButBitS(block, TOG, V3D_SHOW_X, REDRAWVIEW3D, "X Axis", 102, 88, 60, 19, &vd->gridflag, 0, 0, 0, 0, "Show the X Axis line");
- uiDefButBitS(block, TOG, V3D_SHOW_Y, REDRAWVIEW3D, "Y Axis", 166, 88, 60, 19, &vd->gridflag, 0, 0, 0, 0, "Show the Y Axis line");
- uiDefButBitS(block, TOG, V3D_SHOW_Z, REDRAWVIEW3D, "Z Axis", 230, 88, 60, 19, &vd->gridflag, 0, 0, 0, 0, "Show the Z Axis line");
+ uiBlockBeginAlign(block);
+ uiDefButF(block, NUM, REDRAWVIEW3D, "Lens:", 10, 90, 140, 19, &vd->lens, 10.0, 120.0, 100, 0, "The lens angle in perspective view");
+ uiDefButF(block, NUM, REDRAWVIEW3D, "Clip Start:", 10, 70, 140, 19, &vd->near, vd->grid/10.0, 100.0, 10, 0, "Set the beginning of the range in which 3D objects are displayed (perspective view)");
+ uiDefButF(block, NUM, REDRAWVIEW3D, "Clip End:", 10, 50, 140, 19, &vd->far, 1.0, 1000.0*vd->grid, 100, 0, "Set the end of the range in which 3D objects are displayed (perspective view)");
+ uiBlockEndAlign(block);
- uiDefBut(block, LABEL, 1, "View Camera:", 0, 50, 150, 19, NULL, 0.0, 0.0, 0, 0, "");
-
- uiDefButF(block, NUM, REDRAWVIEW3D, "Lens:", 0, 28, 140, 19, &vd->lens, 10.0, 120.0, 100, 0, "The lens angle in perspective view");
-
- uiDefButF(block, NUM, REDRAWVIEW3D, "Clip Start:", 0, 6, 140, 19, &vd->near, vd->grid/10.0, 100.0, 10, 0, "Set the beginning of the range in which 3D objects are displayed (perspective view)");
- uiDefButF(block, NUM, REDRAWVIEW3D, "Clip End:", 150, 6, 140, 19, &vd->far, 1.0, 1000.0*vd->grid, 100, 0, "Set the end of the range in which 3D objects are displayed (perspective view)");
+ uiDefBut(block, LABEL, 1, "3D Cursor:", 160, 110, 140, 19, NULL, 0.0, 0.0, 0, 0, "");
+
+ uiBlockBeginAlign(block);
+ curs= give_cursor();
+ uiDefButF(block, NUM, REDRAWVIEW3D, "X:", 160, 90, 150, 19, curs, -1000.0*vd->grid, 1000.0*vd->grid, 10, 0, "X coordinate of 3d cursor");
+ uiDefButF(block, NUM, REDRAWVIEW3D, "Y:", 160, 70, 150, 19, curs+1, -1000.0*vd->grid, 1000.0*vd->grid, 10, 0, "Y coordinate of 3d cursor");
+ uiDefButF(block, NUM, REDRAWVIEW3D, "Z:", 160, 50, 150, 19, curs+2, -1000.0*vd->grid, 1000.0*vd->grid, 10, 0, "Z coordinate of 3d cursor");
+ uiBlockEndAlign(block);
+
+ uiDefButBitS(block, TOG, V3D_SELECT_OUTLINE, REDRAWVIEW3D, "Draw selection outline", 10, 10, 300, 19, &vd->flag, 0, 0, 0, 0, "In solid drawmode, it adds a selection outline to objects");
}