Changes for FORMS 2.0.

This commit is contained in:
Guido van Rossum 1991-12-10 13:49:34 +00:00
parent 47f2333609
commit ccf0ca2860
2 changed files with 62 additions and 12 deletions

View File

@ -2,6 +2,8 @@
# This corresponds to "forms.h". # This corresponds to "forms.h".
# Recommended use: import FL; ... FL.NORMAL_BOX ... etc. # Recommended use: import FL; ... FL.NORMAL_BOX ... etc.
_v15 = 0
NULL = 0 NULL = 0
FALSE = 0 FALSE = 0
TRUE = 1 TRUE = 1
@ -9,6 +11,7 @@ TRUE = 1
EVENT = -1 EVENT = -1
LABEL_SIZE = 64 LABEL_SIZE = 64
SHORTCUT_SIZE = 32 # V2.0
PLACE_FREE = 0 PLACE_FREE = 0
PLACE_SIZE = 1 PLACE_SIZE = 1
PLACE_ASPECT = 2 PLACE_ASPECT = 2
@ -105,6 +108,7 @@ HIDDEN_BUTTON = 3
TOUCH_BUTTON = 4 TOUCH_BUTTON = 4
INOUT_BUTTON = 5 INOUT_BUTTON = 5
RETURN_BUTTON = 6 RETURN_BUTTON = 6
HIDDEN_RET_BUTTON = 7 # V2.0
BUTTON_BOXTYPE = UP_BOX BUTTON_BOXTYPE = UP_BOX
BUTTON_COL1 = COL1 BUTTON_COL1 = COL1
BUTTON_COL2 = COL1 BUTTON_COL2 = COL1
@ -113,6 +117,20 @@ BUTTON_ALIGN = ALIGN_CENTER
BUTTON_MCOL1 = MCOL BUTTON_MCOL1 = MCOL
BUTTON_MCOL2 = MCOL BUTTON_MCOL2 = MCOL
BUTTON_BW = BOUND_WIDTH BUTTON_BW = BOUND_WIDTH
CHART = 4 # V2.0
BAR_CHART = 0 # V2.0
HORBAR_CHART = 1 # V2.0
LINE_CHART = 2 # V2.0
FILLED_CHART = 3 # V2.0
SPIKE_CHART = 4 # V2.0
PIE_CHART = 5 # V2.0
SPECIALPIE_CHART = 6 # V2.0
CHART_BOXTYPE = BORDER_BOX # V2.0
CHART_COL1 = COL1 # V2.0
CHART_LCOL = LCOL # V2.0
CHART_ALIGN = ALIGN_BOTTOM # V2.0
CHART_BW = BOUND_WIDTH # V2.0
CHART_MAX = 128 # V2.0
CHOICE = 42 CHOICE = 42
NORMAL_CHOICE = 0 NORMAL_CHOICE = 0
CHOICE_BOXTYPE = DOWN_BOX CHOICE_BOXTYPE = DOWN_BOX
@ -142,9 +160,11 @@ COUNTER_COL1 = COL1
COUNTER_COL2 = 4 COUNTER_COL2 = 4
COUNTER_LCOL = LCOL COUNTER_LCOL = LCOL
COUNTER_ALIGN = ALIGN_BOTTOM COUNTER_ALIGN = ALIGN_BOTTOM
DEFAULT = 51 COUNTER_BW = BOUND_WIDTH # V2.0
RETURN_DEFAULT = 0 if _v15:
ALWAYS_DEFAULT = 1 DEFAULT = 51 # V1.5
RETURN_DEFAULT = 0 # V1.5
ALWAYS_DEFAULT = 1 # V1.5
DIAL = 22 DIAL = 22
NORMAL_DIAL = 0 NORMAL_DIAL = 0
LINE_DIAL = 1 LINE_DIAL = 1
@ -163,7 +183,12 @@ CONTINUOUS_FREE = 4
ALL_FREE = 5 ALL_FREE = 5
INPUT = 31 INPUT = 31
NORMAL_INPUT = 0 NORMAL_INPUT = 0
ALWAYS_INPUT = 1 if _v15:
ALWAYS_INPUT = 1 # V1.5 -- Warning: collides with next
else:
FLOAT_INPUT = 1 # V2.0
INT_INPUT = 2 # V2.0
HIDDEN_INPUT = 3 # V2.0
INPUT_BOXTYPE = DOWN_BOX INPUT_BOXTYPE = DOWN_BOX
INPUT_COL1 = 13 INPUT_COL1 = 13
INPUT_COL2 = 5 INPUT_COL2 = 5
@ -217,8 +242,8 @@ VERT_SLIDER = 0
HOR_SLIDER = 1 HOR_SLIDER = 1
VERT_FILL_SLIDER = 2 VERT_FILL_SLIDER = 2
HOR_FILL_SLIDER = 3 HOR_FILL_SLIDER = 3
FL_VERT_NICE_SLIDER = 4 VERT_NICE_SLIDER = 4
FL_HOR_NICE_SLIDER = 5 HOR_NICE_SLIDER = 5
SLIDER_BOXTYPE = DOWN_BOX SLIDER_BOXTYPE = DOWN_BOX
SLIDER_COL1 = COL1 SLIDER_COL1 = COL1
SLIDER_COL2 = COL1 SLIDER_COL2 = COL1

View File

@ -2,6 +2,8 @@
# This corresponds to "forms.h". # This corresponds to "forms.h".
# Recommended use: import FL; ... FL.NORMAL_BOX ... etc. # Recommended use: import FL; ... FL.NORMAL_BOX ... etc.
_v15 = 0
NULL = 0 NULL = 0
FALSE = 0 FALSE = 0
TRUE = 1 TRUE = 1
@ -9,6 +11,7 @@ TRUE = 1
EVENT = -1 EVENT = -1
LABEL_SIZE = 64 LABEL_SIZE = 64
SHORTCUT_SIZE = 32 # V2.0
PLACE_FREE = 0 PLACE_FREE = 0
PLACE_SIZE = 1 PLACE_SIZE = 1
PLACE_ASPECT = 2 PLACE_ASPECT = 2
@ -105,6 +108,7 @@ HIDDEN_BUTTON = 3
TOUCH_BUTTON = 4 TOUCH_BUTTON = 4
INOUT_BUTTON = 5 INOUT_BUTTON = 5
RETURN_BUTTON = 6 RETURN_BUTTON = 6
HIDDEN_RET_BUTTON = 7 # V2.0
BUTTON_BOXTYPE = UP_BOX BUTTON_BOXTYPE = UP_BOX
BUTTON_COL1 = COL1 BUTTON_COL1 = COL1
BUTTON_COL2 = COL1 BUTTON_COL2 = COL1
@ -113,6 +117,20 @@ BUTTON_ALIGN = ALIGN_CENTER
BUTTON_MCOL1 = MCOL BUTTON_MCOL1 = MCOL
BUTTON_MCOL2 = MCOL BUTTON_MCOL2 = MCOL
BUTTON_BW = BOUND_WIDTH BUTTON_BW = BOUND_WIDTH
CHART = 4 # V2.0
BAR_CHART = 0 # V2.0
HORBAR_CHART = 1 # V2.0
LINE_CHART = 2 # V2.0
FILLED_CHART = 3 # V2.0
SPIKE_CHART = 4 # V2.0
PIE_CHART = 5 # V2.0
SPECIALPIE_CHART = 6 # V2.0
CHART_BOXTYPE = BORDER_BOX # V2.0
CHART_COL1 = COL1 # V2.0
CHART_LCOL = LCOL # V2.0
CHART_ALIGN = ALIGN_BOTTOM # V2.0
CHART_BW = BOUND_WIDTH # V2.0
CHART_MAX = 128 # V2.0
CHOICE = 42 CHOICE = 42
NORMAL_CHOICE = 0 NORMAL_CHOICE = 0
CHOICE_BOXTYPE = DOWN_BOX CHOICE_BOXTYPE = DOWN_BOX
@ -142,9 +160,11 @@ COUNTER_COL1 = COL1
COUNTER_COL2 = 4 COUNTER_COL2 = 4
COUNTER_LCOL = LCOL COUNTER_LCOL = LCOL
COUNTER_ALIGN = ALIGN_BOTTOM COUNTER_ALIGN = ALIGN_BOTTOM
DEFAULT = 51 COUNTER_BW = BOUND_WIDTH # V2.0
RETURN_DEFAULT = 0 if _v15:
ALWAYS_DEFAULT = 1 DEFAULT = 51 # V1.5
RETURN_DEFAULT = 0 # V1.5
ALWAYS_DEFAULT = 1 # V1.5
DIAL = 22 DIAL = 22
NORMAL_DIAL = 0 NORMAL_DIAL = 0
LINE_DIAL = 1 LINE_DIAL = 1
@ -163,7 +183,12 @@ CONTINUOUS_FREE = 4
ALL_FREE = 5 ALL_FREE = 5
INPUT = 31 INPUT = 31
NORMAL_INPUT = 0 NORMAL_INPUT = 0
ALWAYS_INPUT = 1 if _v15:
ALWAYS_INPUT = 1 # V1.5 -- Warning: collides with next
else:
FLOAT_INPUT = 1 # V2.0
INT_INPUT = 2 # V2.0
HIDDEN_INPUT = 3 # V2.0
INPUT_BOXTYPE = DOWN_BOX INPUT_BOXTYPE = DOWN_BOX
INPUT_COL1 = 13 INPUT_COL1 = 13
INPUT_COL2 = 5 INPUT_COL2 = 5
@ -217,8 +242,8 @@ VERT_SLIDER = 0
HOR_SLIDER = 1 HOR_SLIDER = 1
VERT_FILL_SLIDER = 2 VERT_FILL_SLIDER = 2
HOR_FILL_SLIDER = 3 HOR_FILL_SLIDER = 3
FL_VERT_NICE_SLIDER = 4 VERT_NICE_SLIDER = 4
FL_HOR_NICE_SLIDER = 5 HOR_NICE_SLIDER = 5
SLIDER_BOXTYPE = DOWN_BOX SLIDER_BOXTYPE = DOWN_BOX
SLIDER_COL1 = COL1 SLIDER_COL1 = COL1
SLIDER_COL2 = COL1 SLIDER_COL2 = COL1