Merged r9481:9518 on jblum/grc_reorganize into trunk. Reorganized grc source under...
[debian/gnuradio] / grc / src / gui / Constants.py
1 """
2 Copyright 2008 Free Software Foundation, Inc.
3 This file is part of GNU Radio
4
5 GNU Radio Companion is free software; you can redistribute it and/or
6 modify it under the terms of the GNU General Public License
7 as published by the Free Software Foundation; either version 2
8 of the License, or (at your option) any later version.
9
10 GNU Radio Companion is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13 GNU General Public License for more details.
14
15 You should have received a copy of the GNU General Public License
16 along with this program; if not, write to the Free Software
17 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
18 """
19
20 ##################################################
21 ## Global Titles
22 ##################################################
23
24 ##The name to appear in the main window for a flow graph that has not been saved to file.
25 NEW_FLOGRAPH_TITLE = 'untitled'
26
27 ##The prefix title on the main window.
28 MAIN_WINDOW_PREFIX = "GRC"
29
30 ##################################################
31 ## Signal block rotations
32 ##################################################
33
34 ##direction of rotation left.
35 DIR_LEFT = 'left'
36
37 ##direction of rotation right.
38 DIR_RIGHT = 'right'
39
40 ##################################################
41 ## Dimension constraints for the various windows (in pixels)
42 ##################################################
43
44 ##main window constraints
45 MIN_WINDOW_WIDTH = 600
46 MIN_WINDOW_HEIGHT = 400
47
48 ##dialog constraints
49 MIN_DIALOG_WIDTH = 500
50 MIN_DIALOG_HEIGHT = 500
51
52 ##static height of reports window
53 REPORTS_WINDOW_HEIGHT = 100
54
55 ##static width of block selection window
56 BLOCK_SELECTION_WINDOW_WIDTH = 200
57
58 ##################################################
59 ## Dragging, scrolling, and redrawing constants for the flow graph window in pixels
60 ##################################################
61
62 ##How close can the mouse get to the window border before mouse events are ignored.
63 BORDER_PROXIMITY_SENSITIVITY = 50
64
65 ##How close the mouse can get to the edge of the visible window before scrolling is invoked.
66 SCROLL_PROXIMITY_SENSITIVITY = 30
67
68 ##When the window has to be scrolled, move it this distance in the required direction.
69 SCROLL_DISTANCE = 15
70
71 ##The redrawing sensitivity, how many seconds must pass between motion events before a redraw?
72 MOTION_DETECT_REDRAWING_SENSITIVITY = .02
73
74 ##How close the mouse click can be to a connection and register a connection select.
75 CONNECTION_SELECT_SENSITIVITY = 5
76
77 ##################################################
78 # A state is recorded for each change to the flow graph, the size dictates how many states we can record
79 ##################################################
80
81 ##The size of the state saving cache in the flow graph (for undo/redo functionality)
82 STATE_CACHE_SIZE = 42