/Lib/plat-mac/lib-scriptpackages/StdSuites/QuickDraw_Graphics_Suite.py

http://unladen-swallow.googlecode.com/ · Python · 417 lines · 325 code · 36 blank · 56 comment · 0 complexity · bff5c2fcd2c4df2d4a50ff320b29ee1a MD5 · raw file

  1. """Suite QuickDraw Graphics Suite: A set of basic classes for graphics
  2. Level 1, version 1
  3. Generated from /Volumes/Sap/System Folder/Extensions/AppleScript
  4. AETE/AEUT resource version 1/0, language 0, script 0
  5. """
  6. import aetools
  7. import MacOS
  8. _code = 'qdrw'
  9. class QuickDraw_Graphics_Suite_Events:
  10. pass
  11. class arc(aetools.ComponentItem):
  12. """arc - An arc """
  13. want = 'carc'
  14. class _Prop_arc_angle(aetools.NProperty):
  15. """arc angle - the angle of the arc in degrees """
  16. which = 'parc'
  17. want = 'fixd'
  18. class _Prop_bounds(aetools.NProperty):
  19. """bounds - the smallest rectangle that contains the entire arc """
  20. which = 'pbnd'
  21. want = 'qdrt'
  22. class _Prop_definition_rect(aetools.NProperty):
  23. """definition rect - the rectangle that contains the circle or oval used to define the arc """
  24. which = 'pdrt'
  25. want = 'qdrt'
  26. class _Prop_fill_color(aetools.NProperty):
  27. """fill color - the fill color """
  28. which = 'flcl'
  29. want = 'cRGB'
  30. class _Prop_fill_pattern(aetools.NProperty):
  31. """fill pattern - the fill pattern """
  32. which = 'flpt'
  33. want = 'cpix'
  34. class _Prop_pen_color(aetools.NProperty):
  35. """pen color - the pen color """
  36. which = 'ppcl'
  37. want = 'cRGB'
  38. class _Prop_pen_pattern(aetools.NProperty):
  39. """pen pattern - the pen pattern """
  40. which = 'pppa'
  41. want = 'cpix'
  42. class _Prop_pen_width(aetools.NProperty):
  43. """pen width - the pen width """
  44. which = 'ppwd'
  45. want = 'shor'
  46. class _Prop_start_angle(aetools.NProperty):
  47. """start angle - the angle that defines the start of the arc, in degrees """
  48. which = 'pang'
  49. want = 'fixd'
  50. class _Prop_transfer_mode(aetools.NProperty):
  51. """transfer mode - the transfer mode """
  52. which = 'pptm'
  53. want = 'tran'
  54. arcs = arc
  55. class drawing_area(aetools.ComponentItem):
  56. """drawing area - Container for graphics and supporting information """
  57. want = 'cdrw'
  58. class _Prop_background_color(aetools.NProperty):
  59. """background color - the color used to fill in unoccupied areas """
  60. which = 'pbcl'
  61. want = 'cRGB'
  62. class _Prop_background_pattern(aetools.NProperty):
  63. """background pattern - the pattern used to fill in unoccupied areas """
  64. which = 'pbpt'
  65. want = 'cpix'
  66. class _Prop_color_table(aetools.NProperty):
  67. """color table - the color table """
  68. which = 'cltb'
  69. want = 'clrt'
  70. class _Prop_default_font(aetools.NProperty):
  71. """default font - the name of the default font for text objects """
  72. which = 'ptxf'
  73. want = 'itxt'
  74. class _Prop_default_location(aetools.NProperty):
  75. """default location - the default location of each new graphic object """
  76. which = 'pnel'
  77. want = 'QDpt'
  78. class _Prop_default_size(aetools.NProperty):
  79. """default size - the default size for text objects """
  80. which = 'ptps'
  81. want = 'fixd'
  82. class _Prop_name(aetools.NProperty):
  83. """name - the name """
  84. which = 'pnam'
  85. want = 'itxt'
  86. class _Prop_ordering(aetools.NProperty):
  87. """ordering - the ordered list of graphic objects in the drawing area """
  88. which = 'gobs'
  89. want = 'obj '
  90. class _Prop_pixel_depth(aetools.NProperty):
  91. """pixel depth - the number of bits per pixel """
  92. which = 'pdpt'
  93. want = 'shor'
  94. class _Prop_style(aetools.NProperty):
  95. """style - the default text style for text objects """
  96. which = 'txst'
  97. want = 'tsty'
  98. class _Prop_text_color(aetools.NProperty):
  99. """text color - the default color for text objects """
  100. which = 'ptxc'
  101. want = 'cRGB'
  102. class _Prop_update_on_change(aetools.NProperty):
  103. """update on change - Redraw after each change? """
  104. which = 'pupd'
  105. want = 'bool'
  106. class _Prop_writing_code(aetools.NProperty):
  107. """writing code - the script system and language of text objects in the drawing area """
  108. which = 'psct'
  109. want = 'intl'
  110. drawing_areas = drawing_area
  111. class graphic_objects(aetools.ComponentItem):
  112. """graphic objects - """
  113. want = 'cgob'
  114. graphic_object = graphic_objects
  115. class graphic_shapes(aetools.ComponentItem):
  116. """graphic shapes - """
  117. want = 'cgsh'
  118. graphic_shape = graphic_shapes
  119. class graphic_text(aetools.ComponentItem):
  120. """graphic text - A series of characters within a drawing area """
  121. want = 'cgtx'
  122. class _Prop_color(aetools.NProperty):
  123. """color - the color of the first character """
  124. which = 'colr'
  125. want = 'cRGB'
  126. class _Prop_font(aetools.NProperty):
  127. """font - the name of the font of the first character """
  128. which = 'font'
  129. want = 'ctxt'
  130. class _Prop_size(aetools.NProperty):
  131. """size - the size in points of the first character """
  132. which = 'ptsz'
  133. want = 'fixd'
  134. class _Prop_uniform_styles(aetools.NProperty):
  135. """uniform styles - the text styles that are uniform throughout the text """
  136. which = 'ustl'
  137. want = 'tsty'
  138. class ovals(aetools.ComponentItem):
  139. """ovals - """
  140. want = 'covl'
  141. oval = ovals
  142. class polygon(aetools.ComponentItem):
  143. """polygon - A polygon """
  144. want = 'cpgn'
  145. class _Prop_point_list(aetools.NProperty):
  146. """point list - the list of points that define the polygon """
  147. which = 'ptlt'
  148. want = 'QDpt'
  149. polygons = polygon
  150. class graphic_groups(aetools.ComponentItem):
  151. """graphic groups - """
  152. want = 'cpic'
  153. graphic_group = graphic_groups
  154. class pixel_maps(aetools.ComponentItem):
  155. """pixel maps - """
  156. want = 'cpix'
  157. pixel_map = pixel_maps
  158. class pixel(aetools.ComponentItem):
  159. """pixel - A pixel """
  160. want = 'cpxl'
  161. pixels = pixel
  162. class rectangles(aetools.ComponentItem):
  163. """rectangles - """
  164. want = 'crec'
  165. rectangle = rectangles
  166. class rounded_rectangle(aetools.ComponentItem):
  167. """rounded rectangle - A rounded rectangle """
  168. want = 'crrc'
  169. class _Prop_corner_curve_height(aetools.NProperty):
  170. """corner curve height - the height of the oval used to define the shape of the rounded corners """
  171. which = 'pchd'
  172. want = 'shor'
  173. class _Prop_corner_curve_width(aetools.NProperty):
  174. """corner curve width - the width of the oval used to define the shape of the rounded corners """
  175. which = 'pcwd'
  176. want = 'shor'
  177. rounded_rectangles = rounded_rectangle
  178. class graphic_line(aetools.ComponentItem):
  179. """graphic line - A graphic line """
  180. want = 'glin'
  181. class _Prop_arrow_style(aetools.NProperty):
  182. """arrow style - the arrow style """
  183. which = 'arro'
  184. want = 'arro'
  185. class _Prop_dash_style(aetools.NProperty):
  186. """dash style - the dash style """
  187. which = 'pdst'
  188. want = 'tdas'
  189. class _Prop_end_point(aetools.NProperty):
  190. """end point - the ending point of the line """
  191. which = 'pend'
  192. want = 'QDpt'
  193. class _Prop_start_point(aetools.NProperty):
  194. """start point - the starting point of the line """
  195. which = 'pstp'
  196. want = 'QDpt'
  197. graphic_lines = graphic_line
  198. arc._superclassnames = []
  199. arc._privpropdict = {
  200. 'arc_angle' : _Prop_arc_angle,
  201. 'bounds' : _Prop_bounds,
  202. 'definition_rect' : _Prop_definition_rect,
  203. 'fill_color' : _Prop_fill_color,
  204. 'fill_pattern' : _Prop_fill_pattern,
  205. 'pen_color' : _Prop_pen_color,
  206. 'pen_pattern' : _Prop_pen_pattern,
  207. 'pen_width' : _Prop_pen_width,
  208. 'start_angle' : _Prop_start_angle,
  209. 'transfer_mode' : _Prop_transfer_mode,
  210. }
  211. arc._privelemdict = {
  212. }
  213. drawing_area._superclassnames = []
  214. drawing_area._privpropdict = {
  215. 'background_color' : _Prop_background_color,
  216. 'background_pattern' : _Prop_background_pattern,
  217. 'color_table' : _Prop_color_table,
  218. 'default_font' : _Prop_default_font,
  219. 'default_location' : _Prop_default_location,
  220. 'default_size' : _Prop_default_size,
  221. 'name' : _Prop_name,
  222. 'ordering' : _Prop_ordering,
  223. 'pixel_depth' : _Prop_pixel_depth,
  224. 'style' : _Prop_style,
  225. 'text_color' : _Prop_text_color,
  226. 'update_on_change' : _Prop_update_on_change,
  227. 'writing_code' : _Prop_writing_code,
  228. }
  229. drawing_area._privelemdict = {
  230. }
  231. graphic_objects._superclassnames = []
  232. graphic_objects._privpropdict = {
  233. }
  234. graphic_objects._privelemdict = {
  235. }
  236. graphic_shapes._superclassnames = []
  237. graphic_shapes._privpropdict = {
  238. }
  239. graphic_shapes._privelemdict = {
  240. }
  241. graphic_text._superclassnames = []
  242. graphic_text._privpropdict = {
  243. 'color' : _Prop_color,
  244. 'font' : _Prop_font,
  245. 'size' : _Prop_size,
  246. 'uniform_styles' : _Prop_uniform_styles,
  247. }
  248. graphic_text._privelemdict = {
  249. }
  250. ovals._superclassnames = []
  251. ovals._privpropdict = {
  252. }
  253. ovals._privelemdict = {
  254. }
  255. polygon._superclassnames = []
  256. polygon._privpropdict = {
  257. 'point_list' : _Prop_point_list,
  258. }
  259. polygon._privelemdict = {
  260. }
  261. graphic_groups._superclassnames = []
  262. graphic_groups._privpropdict = {
  263. }
  264. graphic_groups._privelemdict = {
  265. }
  266. pixel_maps._superclassnames = []
  267. pixel_maps._privpropdict = {
  268. }
  269. pixel_maps._privelemdict = {
  270. }
  271. pixel._superclassnames = []
  272. pixel._privpropdict = {
  273. 'color' : _Prop_color,
  274. }
  275. pixel._privelemdict = {
  276. }
  277. rectangles._superclassnames = []
  278. rectangles._privpropdict = {
  279. }
  280. rectangles._privelemdict = {
  281. }
  282. rounded_rectangle._superclassnames = []
  283. rounded_rectangle._privpropdict = {
  284. 'corner_curve_height' : _Prop_corner_curve_height,
  285. 'corner_curve_width' : _Prop_corner_curve_width,
  286. }
  287. rounded_rectangle._privelemdict = {
  288. }
  289. graphic_line._superclassnames = []
  290. graphic_line._privpropdict = {
  291. 'arrow_style' : _Prop_arrow_style,
  292. 'dash_style' : _Prop_dash_style,
  293. 'end_point' : _Prop_end_point,
  294. 'start_point' : _Prop_start_point,
  295. }
  296. graphic_line._privelemdict = {
  297. }
  298. _Enum_arro = {
  299. 'no_arrow' : 'arno', # No arrow on line
  300. 'arrow_at_start' : 'arst', # Arrow at start of line
  301. 'arrow_at_end' : 'aren', # Arrow at end of line
  302. 'arrow_at_both_ends' : 'arbo', # Arrow at both the start and the end of the line
  303. }
  304. _Enum_tran = {
  305. 'copy_pixels' : 'cpy ', #
  306. 'not_copy_pixels' : 'ncpy', #
  307. 'or_pixels' : 'or ', #
  308. 'not_or_pixels' : 'ntor', #
  309. 'bic_pixels' : 'bic ', #
  310. 'not_bic_pixels' : 'nbic', #
  311. 'xor_pixels' : 'xor ', #
  312. 'not_xor_pixels' : 'nxor', #
  313. 'add_over_pixels' : 'addo', #
  314. 'add_pin_pixels' : 'addp', #
  315. 'sub_over_pixels' : 'subo', #
  316. 'sub_pin_pixels' : 'subp', #
  317. 'ad_max_pixels' : 'admx', #
  318. 'ad_min_pixels' : 'admn', #
  319. 'blend_pixels' : 'blnd', #
  320. }
  321. #
  322. # Indices of types declared in this module
  323. #
  324. _classdeclarations = {
  325. 'carc' : arc,
  326. 'cdrw' : drawing_area,
  327. 'cgob' : graphic_objects,
  328. 'cgsh' : graphic_shapes,
  329. 'cgtx' : graphic_text,
  330. 'covl' : ovals,
  331. 'cpgn' : polygon,
  332. 'cpic' : graphic_groups,
  333. 'cpix' : pixel_maps,
  334. 'cpxl' : pixel,
  335. 'crec' : rectangles,
  336. 'crrc' : rounded_rectangle,
  337. 'glin' : graphic_line,
  338. }
  339. _propdeclarations = {
  340. 'arro' : _Prop_arrow_style,
  341. 'cltb' : _Prop_color_table,
  342. 'colr' : _Prop_color,
  343. 'flcl' : _Prop_fill_color,
  344. 'flpt' : _Prop_fill_pattern,
  345. 'font' : _Prop_font,
  346. 'gobs' : _Prop_ordering,
  347. 'pang' : _Prop_start_angle,
  348. 'parc' : _Prop_arc_angle,
  349. 'pbcl' : _Prop_background_color,
  350. 'pbnd' : _Prop_bounds,
  351. 'pbpt' : _Prop_background_pattern,
  352. 'pchd' : _Prop_corner_curve_height,
  353. 'pcwd' : _Prop_corner_curve_width,
  354. 'pdpt' : _Prop_pixel_depth,
  355. 'pdrt' : _Prop_definition_rect,
  356. 'pdst' : _Prop_dash_style,
  357. 'pend' : _Prop_end_point,
  358. 'pnam' : _Prop_name,
  359. 'pnel' : _Prop_default_location,
  360. 'ppcl' : _Prop_pen_color,
  361. 'pppa' : _Prop_pen_pattern,
  362. 'pptm' : _Prop_transfer_mode,
  363. 'ppwd' : _Prop_pen_width,
  364. 'psct' : _Prop_writing_code,
  365. 'pstp' : _Prop_start_point,
  366. 'ptlt' : _Prop_point_list,
  367. 'ptps' : _Prop_default_size,
  368. 'ptsz' : _Prop_size,
  369. 'ptxc' : _Prop_text_color,
  370. 'ptxf' : _Prop_default_font,
  371. 'pupd' : _Prop_update_on_change,
  372. 'txst' : _Prop_style,
  373. 'ustl' : _Prop_uniform_styles,
  374. }
  375. _compdeclarations = {
  376. }
  377. _enumdeclarations = {
  378. 'arro' : _Enum_arro,
  379. 'tran' : _Enum_tran,
  380. }