home *** CD-ROM | disk | FTP | other *** search
- /*
- * Standard set of macros for Modeler requesters. Gives them a
- * consistent look (if nothing else).
- */
-
- /* Ok/Cancel gadgets, numbers "ok" and "can"
- * It's an hbox with the gadgets pressed apart with a filler.
- * Also has the extended gadget data for these gadgets.
- */
- #define OKCAN(ok,can) \
- (h|(v-(v(b 0 3)(h(b 5 0)(t 2"Ok")(b 5 0))(b 0 2)):ok-)| \
- (b 5 0) f (b 5 0) \
- |(v-(v(b 0 3)(h (b 5 0)(t 3"Cancel")(b 5 0))(b 0 2)):can-)|)
- #define OKCAN_EXT(ok,can) \
- ok:"OK_ID""ev" can:"CAN_ID""ev"
-
- /* An underlined title string centered in an hbox.
- */
- #define TITLE(str) (h f(v(t 3 str)(-1 3))f)
-
- /* Text centered in a vbox -- for labeling larger boxes.
- */
- #define LABEL(txt) (v f(t txt)f)
-
- /* String gadget with a more complex box around it. Starting text is
- * "txt", gadget number is "num."
- */
- #define STRGAD(txt,num) \
- (h|(v-(-1 2)(h(|1 2)(|1 2)(t txt):num(|1 2)(|1 2))(-1 2)-)|)
-
- /* Scale gadgets. The +/- buttons and scale indicator.
- */
- #define SCALE(up,down) \
- (v f \
- (h f (t 3"Scale") f) \
- (h (t 1"+"):up f (t 1"mm") f (t 1"-"):down) \
- f)
- #define SCALE_EXT(up,down) up:"SCLU_ID""v" down:"SCLD_ID""v"
-
- /* Does the boilerplate to start and end a requester. The boxes between
- * start and end will lie within a vbox with a nice border around it.
- */
- #define START_REQ (h | (v - (h (b 8 0) (v (b 0 8)
- #define END_REQ (b 0 8))(b 8 0)) - ) | )
-
- /* Layer gadgets centered in an hbox.
- * Always numbered 10-17.
- */
- #define LAYGAD \
- (h f (v f(t 1"Layer")f) (b 5 0) | \
- (v - (b 0 3) (h (b 2 0) \
- (t"1"):10(b 2 0)(t"2"):11(b 2 0)(t"3"):12(b 2 0)(t"4"):13(b 2 0) \
- (t"5"):14(b 2 0)(t"6"):15(b 2 0)(t"7"):16(b 2 0)(t"8"):17(b 2 0) \
- ) (b 0 2) -) \
- | f)
- #define LAYGAD_EXT \
- 10:"BUF_ID""ti" 11:"BUF_ID+1""ti"\
- 12:"BUF_ID+2""ti" 13:"BUF_ID+3""ti"\
- 14:"BUF_ID+4""ti" 15:"BUF_ID+5""ti"\
- 16:"BUF_ID+6""ti" 17:"BUF_ID+7""ti"
-