wxruby3 1.6.0 → 1.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (541) hide show
  1. checksums.yaml +4 -4
  2. data/CREDITS.md +32 -25
  3. data/INSTALL.md +21 -6
  4. data/README.md +5 -5
  5. data/assets/repo-social-preview.odg +0 -0
  6. data/assets/repo-social-preview.xcf +0 -0
  7. data/ext/wxruby3/include/wxRubyApp.h +58 -45
  8. data/ext/wxruby3/include/wxruby-runtime.h +78 -1
  9. data/ext/wxruby3/swig/common.i +2 -2
  10. data/ext/wxruby3/swig/custom/director.swg +2 -2
  11. data/ext/wxruby3/swig/custom/rubyprimtypes.swg +59 -15
  12. data/ext/wxruby3/swig/custom/rubyrun.swg +4 -0
  13. data/ext/wxruby3/swig/custom/rubytracking.swg +4 -0
  14. data/ext/wxruby3/swig/custom/swiglabels.swg +129 -0
  15. data/ext/wxruby3/swig/custom/swigrun.swg +15 -0
  16. data/ext/wxruby3/swig/custom/typemaps/swigtypemaps.swg +20 -0
  17. data/ext/wxruby3/swig/mark_free_impl.i +154 -88
  18. data/ext/wxruby3/swig/memory_management.i +1 -0
  19. data/ext/wxruby3/swig/wx.i +73 -44
  20. data/lib/wx/aui/events/evt_list.rb +148 -0
  21. data/lib/wx/aui/require.rb +0 -1
  22. data/lib/wx/core/calendar_ctrl.rb +15 -0
  23. data/lib/wx/core/clipboard.rb +9 -13
  24. data/lib/wx/core/config.rb +1 -1
  25. data/lib/wx/core/events/evt_list.rb +1458 -0
  26. data/lib/wx/core/font/encoding.rb +113 -0
  27. data/lib/wx/core/generic_validator.rb +83 -31
  28. data/lib/wx/core/tipwindow.rb +16 -0
  29. data/lib/wx/core/variant.rb +6 -0
  30. data/lib/wx/doc/aui/auitabctrl.rb +35 -0
  31. data/lib/wx/doc/config.rb +2 -2
  32. data/lib/wx/doc/functions.rb +1 -1
  33. data/lib/wx/doc/gen/about_dialog_info.rb +330 -0
  34. data/lib/wx/doc/gen/accelerator.rb +178 -0
  35. data/lib/wx/doc/gen/activity_indicator.rb +83 -0
  36. data/lib/wx/doc/gen/affine_matrix2d.rb +284 -0
  37. data/lib/wx/doc/gen/animation.rb +275 -0
  38. data/lib/wx/doc/gen/animation_ctrl.rb +300 -0
  39. data/lib/wx/doc/gen/any_button.rb +191 -0
  40. data/lib/wx/doc/gen/app.rb +463 -0
  41. data/lib/wx/doc/gen/app_traits.rb +396 -0
  42. data/lib/wx/doc/gen/art_provider.rb +605 -0
  43. data/lib/wx/doc/gen/aui/aui_dock_art.rb +455 -0
  44. data/lib/wx/doc/gen/aui/aui_floating_frame.rb +54 -0
  45. data/lib/wx/doc/gen/aui/aui_manager.rb +847 -0
  46. data/lib/wx/doc/gen/aui/aui_manager_event.rb +131 -0
  47. data/lib/wx/doc/gen/aui/aui_mdi_child_frame.rb +180 -0
  48. data/lib/wx/doc/gen/aui/aui_mdi_client_window.rb +59 -0
  49. data/lib/wx/doc/gen/aui/aui_mdi_parent_frame.rb +130 -0
  50. data/lib/wx/doc/gen/aui/aui_notebook.rb +631 -0
  51. data/lib/wx/doc/gen/aui/aui_notebook_event.rb +233 -0
  52. data/lib/wx/doc/gen/aui/aui_pane_info.rb +769 -0
  53. data/lib/wx/doc/gen/aui/aui_tab_art.rb +352 -0
  54. data/lib/wx/doc/gen/aui/aui_tab_ctrl.rb +14 -0
  55. data/lib/wx/doc/gen/aui/aui_tool_bar.rb +510 -0
  56. data/lib/wx/doc/gen/aui/aui_tool_bar_art.rb +340 -0
  57. data/lib/wx/doc/gen/aui/aui_tool_bar_event.rb +244 -0
  58. data/lib/wx/doc/gen/aui/aui_tool_bar_item.rb +257 -0
  59. data/lib/wx/doc/gen/aui/event_list.rb +179 -0
  60. data/lib/wx/doc/gen/banner_window.rb +124 -0
  61. data/lib/wx/doc/gen/bitmap.rb +731 -0
  62. data/lib/wx/doc/gen/bitmap_button.rb +123 -0
  63. data/lib/wx/doc/gen/bitmap_combo_box.rb +221 -0
  64. data/lib/wx/doc/gen/book_ctrl_base.rb +273 -0
  65. data/lib/wx/doc/gen/book_ctrl_event.rb +66 -0
  66. data/lib/wx/doc/gen/box_sizer.rb +85 -0
  67. data/lib/wx/doc/gen/brush.rb +251 -0
  68. data/lib/wx/doc/gen/busy_info.rb +157 -0
  69. data/lib/wx/doc/gen/button.rb +182 -0
  70. data/lib/wx/doc/gen/calculate_layout_event.rb +62 -0
  71. data/lib/wx/doc/gen/calendar_ctrl.rb +505 -0
  72. data/lib/wx/doc/gen/calendar_date_attr.rb +138 -0
  73. data/lib/wx/doc/gen/calendar_event.rb +147 -0
  74. data/lib/wx/doc/gen/caret.rb +97 -0
  75. data/lib/wx/doc/gen/check_box.rb +175 -0
  76. data/lib/wx/doc/gen/check_list_box.rb +121 -0
  77. data/lib/wx/doc/gen/choice.rb +175 -0
  78. data/lib/wx/doc/gen/choicebook.rb +116 -0
  79. data/lib/wx/doc/gen/client_dc.rb +43 -0
  80. data/lib/wx/doc/gen/clipboard.rb +144 -0
  81. data/lib/wx/doc/gen/collapsible_pane.rb +138 -0
  82. data/lib/wx/doc/gen/collapsible_pane_event.rb +46 -0
  83. data/lib/wx/doc/gen/colour.rb +333 -0
  84. data/lib/wx/doc/gen/colour_dialog.rb +190 -0
  85. data/lib/wx/doc/gen/colour_picker_ctrl.rb +110 -0
  86. data/lib/wx/doc/gen/colour_picker_event.rb +77 -0
  87. data/lib/wx/doc/gen/combo_box.rb +292 -0
  88. data/lib/wx/doc/gen/combo_ctrl.rb +662 -0
  89. data/lib/wx/doc/gen/command_link_button.rb +134 -0
  90. data/lib/wx/doc/gen/config_base.rb +10 -0
  91. data/lib/wx/doc/gen/context_help_button.rb +109 -0
  92. data/lib/wx/doc/gen/control.rb +277 -0
  93. data/lib/wx/doc/gen/control_with_items.rb +253 -0
  94. data/lib/wx/doc/gen/core.rb +45 -0
  95. data/lib/wx/doc/gen/credential_entry_dialog.rb +137 -0
  96. data/lib/wx/doc/gen/cursor.rb +193 -0
  97. data/lib/wx/doc/gen/data_format.rb +85 -0
  98. data/lib/wx/doc/gen/data_object.rb +436 -0
  99. data/lib/wx/doc/gen/data_object_simple_base.rb +10 -0
  100. data/lib/wx/doc/gen/date_event.rb +49 -0
  101. data/lib/wx/doc/gen/date_picker_ctrl.rb +161 -0
  102. data/lib/wx/doc/gen/dc.rb +1631 -0
  103. data/lib/wx/doc/gen/dc_overlay.rb +102 -0
  104. data/lib/wx/doc/gen/defs.rb +2802 -0
  105. data/lib/wx/doc/gen/dial_up_event.rb +45 -0
  106. data/lib/wx/doc/gen/dial_up_manager.rb +149 -0
  107. data/lib/wx/doc/gen/dialog.rb +541 -0
  108. data/lib/wx/doc/gen/dir_dialog.rb +164 -0
  109. data/lib/wx/doc/gen/dir_filter_list_ctrl.rb +90 -0
  110. data/lib/wx/doc/gen/dir_picker_ctrl.rb +125 -0
  111. data/lib/wx/doc/gen/display.rb +238 -0
  112. data/lib/wx/doc/gen/drag_drop.rb +299 -0
  113. data/lib/wx/doc/gen/drag_image.rb +116 -0
  114. data/lib/wx/doc/gen/editable_list_box.rb +109 -0
  115. data/lib/wx/doc/gen/event.rb +990 -0
  116. data/lib/wx/doc/gen/event_blocker.rb +50 -0
  117. data/lib/wx/doc/gen/event_filter.rb +92 -0
  118. data/lib/wx/doc/gen/event_list.rb +1644 -0
  119. data/lib/wx/doc/gen/events.rb +2809 -0
  120. data/lib/wx/doc/gen/evt_handler.rb +229 -0
  121. data/lib/wx/doc/gen/ext_help_controller.rb +109 -0
  122. data/lib/wx/doc/gen/file_ctrl.rb +231 -0
  123. data/lib/wx/doc/gen/file_ctrl_event.rb +83 -0
  124. data/lib/wx/doc/gen/file_dialog.rb +353 -0
  125. data/lib/wx/doc/gen/file_dialog_custom_control.rb +165 -0
  126. data/lib/wx/doc/gen/file_dialog_customize_hook.rb +158 -0
  127. data/lib/wx/doc/gen/file_dir_picker_event.rb +100 -0
  128. data/lib/wx/doc/gen/file_picker_ctrl.rb +132 -0
  129. data/lib/wx/doc/gen/file_system.rb +232 -0
  130. data/lib/wx/doc/gen/find_dialog_event.rb +126 -0
  131. data/lib/wx/doc/gen/find_replace_data.rb +60 -0
  132. data/lib/wx/doc/gen/find_replace_dialog.rb +58 -0
  133. data/lib/wx/doc/gen/flex_grid_sizer.rb +199 -0
  134. data/lib/wx/doc/gen/font.rb +1379 -0
  135. data/lib/wx/doc/gen/font_data.rb +151 -0
  136. data/lib/wx/doc/gen/font_dialog.rb +88 -0
  137. data/lib/wx/doc/gen/font_picker_ctrl.rb +143 -0
  138. data/lib/wx/doc/gen/font_picker_event.rb +65 -0
  139. data/lib/wx/doc/gen/frame.rb +352 -0
  140. data/lib/wx/doc/gen/fs_file.rb +337 -0
  141. data/lib/wx/doc/gen/functions.rb +10 -0
  142. data/lib/wx/doc/gen/gauge.rb +157 -0
  143. data/lib/wx/doc/gen/gb_sizer_item.rb +68 -0
  144. data/lib/wx/doc/gen/gcdc.rb +46 -0
  145. data/lib/wx/doc/gen/gdi_common.rb +1271 -0
  146. data/lib/wx/doc/gen/gdi_object.rb +31 -0
  147. data/lib/wx/doc/gen/generic_about_dialog.rb +140 -0
  148. data/lib/wx/doc/gen/generic_dir_ctrl.rb +223 -0
  149. data/lib/wx/doc/gen/geometry.rb +661 -0
  150. data/lib/wx/doc/gen/graphics_context.rb +1184 -0
  151. data/lib/wx/doc/gen/graphics_object.rb +750 -0
  152. data/lib/wx/doc/gen/grid/event_list.rb +191 -0
  153. data/lib/wx/doc/gen/grid/grid_cell_activatable_editor.rb +40 -0
  154. data/lib/wx/doc/gen/grid/grid_cell_attr.rb +280 -0
  155. data/lib/wx/doc/gen/grid/grid_cell_auto_wrap_string_editor.rb +35 -0
  156. data/lib/wx/doc/gen/grid/grid_cell_auto_wrap_string_renderer.rb +37 -0
  157. data/lib/wx/doc/gen/grid/grid_cell_bool_editor.rb +49 -0
  158. data/lib/wx/doc/gen/grid/grid_cell_bool_renderer.rb +35 -0
  159. data/lib/wx/doc/gen/grid/grid_cell_choice_editor.rb +46 -0
  160. data/lib/wx/doc/gen/grid/grid_cell_date_editor.rb +38 -0
  161. data/lib/wx/doc/gen/grid/grid_cell_date_renderer.rb +45 -0
  162. data/lib/wx/doc/gen/grid/grid_cell_date_time_renderer.rb +40 -0
  163. data/lib/wx/doc/gen/grid/grid_cell_editor.rb +197 -0
  164. data/lib/wx/doc/gen/grid/grid_cell_enum_editor.rb +39 -0
  165. data/lib/wx/doc/gen/grid/grid_cell_enum_renderer.rb +44 -0
  166. data/lib/wx/doc/gen/grid/grid_cell_float_editor.rb +45 -0
  167. data/lib/wx/doc/gen/grid/grid_cell_float_renderer.rb +79 -0
  168. data/lib/wx/doc/gen/grid/grid_cell_number_editor.rb +46 -0
  169. data/lib/wx/doc/gen/grid/grid_cell_number_renderer.rb +35 -0
  170. data/lib/wx/doc/gen/grid/grid_cell_renderer.rb +108 -0
  171. data/lib/wx/doc/gen/grid/grid_cell_string_renderer.rb +35 -0
  172. data/lib/wx/doc/gen/grid/grid_cell_text_editor.rb +49 -0
  173. data/lib/wx/doc/gen/grid/grid_ctrl.rb +3002 -0
  174. data/lib/wx/doc/gen/grid/grid_editor_created_event.rb +95 -0
  175. data/lib/wx/doc/gen/grid/grid_event.rb +129 -0
  176. data/lib/wx/doc/gen/grid/grid_range_select_event.rb +104 -0
  177. data/lib/wx/doc/gen/grid/grid_size_event.rb +85 -0
  178. data/lib/wx/doc/gen/grid/grid_string_table.rb +142 -0
  179. data/lib/wx/doc/gen/grid/grid_table_base.rb +317 -0
  180. data/lib/wx/doc/gen/grid/grid_table_message.rb +81 -0
  181. data/lib/wx/doc/gen/grid_bag_sizer.rb +323 -0
  182. data/lib/wx/doc/gen/grid_sizer.rb +195 -0
  183. data/lib/wx/doc/gen/gui_event_loop.rb +159 -0
  184. data/lib/wx/doc/gen/h_scrolled_window.rb +562 -0
  185. data/lib/wx/doc/gen/header_ctrl.rb +880 -0
  186. data/lib/wx/doc/gen/header_ctrl_event.rb +133 -0
  187. data/lib/wx/doc/gen/help_controller.rb +195 -0
  188. data/lib/wx/doc/gen/help_provider.rb +98 -0
  189. data/lib/wx/doc/gen/html/event_list.rb +38 -0
  190. data/lib/wx/doc/gen/html/html_cell.rb +536 -0
  191. data/lib/wx/doc/gen/html/html_cell_event.rb +69 -0
  192. data/lib/wx/doc/gen/html/html_data_object.rb +42 -0
  193. data/lib/wx/doc/gen/html/html_easy_printing.rb +203 -0
  194. data/lib/wx/doc/gen/html/html_help_controller.rb +340 -0
  195. data/lib/wx/doc/gen/html/html_help_data.rb +159 -0
  196. data/lib/wx/doc/gen/html/html_help_window.rb +258 -0
  197. data/lib/wx/doc/gen/html/html_link_event.rb +41 -0
  198. data/lib/wx/doc/gen/html/html_list_box.rb +346 -0
  199. data/lib/wx/doc/gen/html/html_printout.rb +109 -0
  200. data/lib/wx/doc/gen/html/html_window.rb +461 -0
  201. data/lib/wx/doc/gen/hyperlink_ctrl.rb +311 -0
  202. data/lib/wx/doc/gen/hyperlink_event.rb +44 -0
  203. data/lib/wx/doc/gen/icon.rb +267 -0
  204. data/lib/wx/doc/gen/icon_location.rb +40 -0
  205. data/lib/wx/doc/gen/image.rb +1371 -0
  206. data/lib/wx/doc/gen/image_list.rb +168 -0
  207. data/lib/wx/doc/gen/info_bar.rb +195 -0
  208. data/lib/wx/doc/gen/keyboard_state.rb +140 -0
  209. data/lib/wx/doc/gen/list_box.rb +304 -0
  210. data/lib/wx/doc/gen/list_ctrl.rb +1774 -0
  211. data/lib/wx/doc/gen/list_event.rb +208 -0
  212. data/lib/wx/doc/gen/listbook.rb +116 -0
  213. data/lib/wx/doc/gen/locale.rb +4293 -0
  214. data/lib/wx/doc/gen/log.rb +603 -0
  215. data/lib/wx/doc/gen/mdi_client_window.rb +47 -0
  216. data/lib/wx/doc/gen/mdi_frame.rb +324 -0
  217. data/lib/wx/doc/gen/media_ctrl.rb +269 -0
  218. data/lib/wx/doc/gen/media_event.rb +117 -0
  219. data/lib/wx/doc/gen/memory_dc.rb +174 -0
  220. data/lib/wx/doc/gen/menu.rb +509 -0
  221. data/lib/wx/doc/gen/menu_bar.rb +287 -0
  222. data/lib/wx/doc/gen/menu_item.rb +362 -0
  223. data/lib/wx/doc/gen/message_dialog.rb +238 -0
  224. data/lib/wx/doc/gen/mini_frame.rb +108 -0
  225. data/lib/wx/doc/gen/mirror_dc.rb +22 -0
  226. data/lib/wx/doc/gen/mouse_state.rb +150 -0
  227. data/lib/wx/doc/gen/multi_choice_dialog.rb +80 -0
  228. data/lib/wx/doc/gen/non_owned_window.rb +49 -0
  229. data/lib/wx/doc/gen/notebook.rb +278 -0
  230. data/lib/wx/doc/gen/num_validator.rb +37 -0
  231. data/lib/wx/doc/gen/number_entry_dialog.rb +93 -0
  232. data/lib/wx/doc/gen/object.rb +59 -0
  233. data/lib/wx/doc/gen/owner_drawn_combo_box.rb +395 -0
  234. data/lib/wx/doc/gen/paint_dc.rb +27 -0
  235. data/lib/wx/doc/gen/palette.rb +92 -0
  236. data/lib/wx/doc/gen/panel.rb +127 -0
  237. data/lib/wx/doc/gen/pen.rb +511 -0
  238. data/lib/wx/doc/gen/persistence_manager.rb +135 -0
  239. data/lib/wx/doc/gen/persistent_object.rb +52 -0
  240. data/lib/wx/doc/gen/persistent_window.rb +241 -0
  241. data/lib/wx/doc/gen/pg/event_list.rb +106 -0
  242. data/lib/wx/doc/gen/pg/numeric_property_validator.rb +54 -0
  243. data/lib/wx/doc/gen/pg/pg_array_editor_dialog.rb +292 -0
  244. data/lib/wx/doc/gen/pg/pg_cell.rb +177 -0
  245. data/lib/wx/doc/gen/pg/pg_editor.rb +721 -0
  246. data/lib/wx/doc/gen/pg/pg_multi_button.rb +152 -0
  247. data/lib/wx/doc/gen/pg/pg_properties.rb +2829 -0
  248. data/lib/wx/doc/gen/pg/pg_property.rb +2078 -0
  249. data/lib/wx/doc/gen/pg/pg_validation_info.rb +344 -0
  250. data/lib/wx/doc/gen/pg/property_grid.rb +740 -0
  251. data/lib/wx/doc/gen/pg/property_grid_event.rb +184 -0
  252. data/lib/wx/doc/gen/pg/property_grid_interface.rb +1098 -0
  253. data/lib/wx/doc/gen/pg/property_grid_manager.rb +415 -0
  254. data/lib/wx/doc/gen/pg/property_grid_page.rb +354 -0
  255. data/lib/wx/doc/gen/pg/property_grid_page_state.rb +165 -0
  256. data/lib/wx/doc/gen/picker_base.rb +152 -0
  257. data/lib/wx/doc/gen/platform_info.rb +622 -0
  258. data/lib/wx/doc/gen/popup_window.rb +107 -0
  259. data/lib/wx/doc/gen/progress_dialog.rb +100 -0
  260. data/lib/wx/doc/gen/property_sheet_dialog.rb +216 -0
  261. data/lib/wx/doc/gen/prt/event_list.rb +17 -0
  262. data/lib/wx/doc/gen/prt/page_setup_dialog.rb +44 -0
  263. data/lib/wx/doc/gen/prt/post_script_dc.rb +30 -0
  264. data/lib/wx/doc/gen/prt/preview_frame.rb +78 -0
  265. data/lib/wx/doc/gen/prt/print_abort_dialog.rb +151 -0
  266. data/lib/wx/doc/gen/prt/print_data.rb +804 -0
  267. data/lib/wx/doc/gen/prt/print_dialog.rb +55 -0
  268. data/lib/wx/doc/gen/prt/printer.rb +518 -0
  269. data/lib/wx/doc/gen/prt/printer_dc.rb +37 -0
  270. data/lib/wx/doc/gen/query_layout_info_event.rb +106 -0
  271. data/lib/wx/doc/gen/radio_box.rb +306 -0
  272. data/lib/wx/doc/gen/radio_button.rb +159 -0
  273. data/lib/wx/doc/gen/rbn/event_list.rb +136 -0
  274. data/lib/wx/doc/gen/rbn/ribbon_art_provider.rb +1132 -0
  275. data/lib/wx/doc/gen/rbn/ribbon_bar.rb +308 -0
  276. data/lib/wx/doc/gen/rbn/ribbon_bar_event.rb +45 -0
  277. data/lib/wx/doc/gen/rbn/ribbon_button_bar.rb +458 -0
  278. data/lib/wx/doc/gen/rbn/ribbon_button_bar_event.rb +63 -0
  279. data/lib/wx/doc/gen/rbn/ribbon_control.rb +143 -0
  280. data/lib/wx/doc/gen/rbn/ribbon_gallery.rb +229 -0
  281. data/lib/wx/doc/gen/rbn/ribbon_gallery_event.rb +55 -0
  282. data/lib/wx/doc/gen/rbn/ribbon_page.rb +174 -0
  283. data/lib/wx/doc/gen/rbn/ribbon_panel.rb +270 -0
  284. data/lib/wx/doc/gen/rbn/ribbon_panel_event.rb +45 -0
  285. data/lib/wx/doc/gen/rbn/ribbon_tool_bar.rb +360 -0
  286. data/lib/wx/doc/gen/rbn/ribbon_tool_bar_event.rb +42 -0
  287. data/lib/wx/doc/gen/rearrange_ctrl.rb +78 -0
  288. data/lib/wx/doc/gen/rearrange_list.rb +123 -0
  289. data/lib/wx/doc/gen/region.rb +380 -0
  290. data/lib/wx/doc/gen/region_iterator.rb +76 -0
  291. data/lib/wx/doc/gen/rich_tool_tip.rb +154 -0
  292. data/lib/wx/doc/gen/rtc/event_list.rb +125 -0
  293. data/lib/wx/doc/gen/rtc/rich_text_box.rb +445 -0
  294. data/lib/wx/doc/gen/rtc/rich_text_buffer.rb +1188 -0
  295. data/lib/wx/doc/gen/rtc/rich_text_buffer_data_object.rb +41 -0
  296. data/lib/wx/doc/gen/rtc/rich_text_composite_object.rb +538 -0
  297. data/lib/wx/doc/gen/rtc/rich_text_ctrl.rb +2103 -0
  298. data/lib/wx/doc/gen/rtc/rich_text_event.rb +173 -0
  299. data/lib/wx/doc/gen/rtc/rich_text_file_handler.rb +181 -0
  300. data/lib/wx/doc/gen/rtc/rich_text_formatting_dialog.rb +319 -0
  301. data/lib/wx/doc/gen/rtc/rich_text_header_footer_data.rb +193 -0
  302. data/lib/wx/doc/gen/rtc/rich_text_html_handler.rb +102 -0
  303. data/lib/wx/doc/gen/rtc/rich_text_image.rb +337 -0
  304. data/lib/wx/doc/gen/rtc/rich_text_object.rb +2922 -0
  305. data/lib/wx/doc/gen/rtc/rich_text_paragraph_layout_box.rb +1240 -0
  306. data/lib/wx/doc/gen/rtc/rich_text_printing.rb +258 -0
  307. data/lib/wx/doc/gen/rtc/rich_text_style_list_box.rb +344 -0
  308. data/lib/wx/doc/gen/rtc/rich_text_style_organiser_dialog.rb +227 -0
  309. data/lib/wx/doc/gen/rtc/rich_text_xml_handler.rb +59 -0
  310. data/lib/wx/doc/gen/rtc/symbol_picker_dialog.rb +169 -0
  311. data/lib/wx/doc/gen/sash_event.rb +147 -0
  312. data/lib/wx/doc/gen/sash_layout_window.rb +232 -0
  313. data/lib/wx/doc/gen/sash_window.rb +171 -0
  314. data/lib/wx/doc/gen/scaled_dc.rb +10 -0
  315. data/lib/wx/doc/gen/screen_dc.rb +30 -0
  316. data/lib/wx/doc/gen/scroll_bar.rb +204 -0
  317. data/lib/wx/doc/gen/scrolled_canvas.rb +410 -0
  318. data/lib/wx/doc/gen/scrolled_control.rb +410 -0
  319. data/lib/wx/doc/gen/scrolled_window.rb +430 -0
  320. data/lib/wx/doc/gen/search_ctrl.rb +159 -0
  321. data/lib/wx/doc/gen/secret_store.rb +116 -0
  322. data/lib/wx/doc/gen/simplebook.rb +110 -0
  323. data/lib/wx/doc/gen/single_choice_dialog.rb +89 -0
  324. data/lib/wx/doc/gen/sizer.rb +945 -0
  325. data/lib/wx/doc/gen/sizer_item.rb +244 -0
  326. data/lib/wx/doc/gen/slider.rb +342 -0
  327. data/lib/wx/doc/gen/spin_button.rb +157 -0
  328. data/lib/wx/doc/gen/spin_ctrl.rb +231 -0
  329. data/lib/wx/doc/gen/spin_ctrl_double.rb +192 -0
  330. data/lib/wx/doc/gen/spin_double_event.rb +55 -0
  331. data/lib/wx/doc/gen/spin_event.rb +51 -0
  332. data/lib/wx/doc/gen/splash_screen.rb +113 -0
  333. data/lib/wx/doc/gen/splitter_event.rb +99 -0
  334. data/lib/wx/doc/gen/splitter_window.rb +498 -0
  335. data/lib/wx/doc/gen/static_bitmap.rb +256 -0
  336. data/lib/wx/doc/gen/static_box.rb +180 -0
  337. data/lib/wx/doc/gen/static_box_sizer.rb +85 -0
  338. data/lib/wx/doc/gen/static_line.rb +83 -0
  339. data/lib/wx/doc/gen/static_text.rb +127 -0
  340. data/lib/wx/doc/gen/status_bar.rb +290 -0
  341. data/lib/wx/doc/gen/stc/event_list.rb +221 -0
  342. data/lib/wx/doc/gen/stc/styled_text_ctrl.rb +4474 -0
  343. data/lib/wx/doc/gen/stc/styled_text_event.rb +8762 -0
  344. data/lib/wx/doc/gen/std_dialog_button_sizer.rb +129 -0
  345. data/lib/wx/doc/gen/svg_file_dc.rb +164 -0
  346. data/lib/wx/doc/gen/system_options.rb +129 -0
  347. data/lib/wx/doc/gen/system_settings.rb +507 -0
  348. data/lib/wx/doc/gen/task_bar_icon.rb +127 -0
  349. data/lib/wx/doc/gen/task_bar_icon_event.rb +88 -0
  350. data/lib/wx/doc/gen/text_attr.rb +756 -0
  351. data/lib/wx/doc/gen/text_ctrl.rb +1033 -0
  352. data/lib/wx/doc/gen/text_entry.rb +441 -0
  353. data/lib/wx/doc/gen/text_entry_dialog.rb +220 -0
  354. data/lib/wx/doc/gen/text_validator.rb +245 -0
  355. data/lib/wx/doc/gen/time_picker_ctrl.rb +128 -0
  356. data/lib/wx/doc/gen/timer.rb +119 -0
  357. data/lib/wx/doc/gen/timer_event.rb +68 -0
  358. data/lib/wx/doc/gen/tip_provider.rb +63 -0
  359. data/lib/wx/doc/gen/tip_window.rb +51 -0
  360. data/lib/wx/doc/gen/toggle_button.rb +182 -0
  361. data/lib/wx/doc/gen/tool_bar.rb +890 -0
  362. data/lib/wx/doc/gen/tool_tip.rb +86 -0
  363. data/lib/wx/doc/gen/toolbook.rb +118 -0
  364. data/lib/wx/doc/gen/top_level_window.rb +497 -0
  365. data/lib/wx/doc/gen/tree_ctrl.rb +1052 -0
  366. data/lib/wx/doc/gen/tree_event.rb +127 -0
  367. data/lib/wx/doc/gen/treebook.rb +180 -0
  368. data/lib/wx/doc/gen/ui_action_simulator.rb +109 -0
  369. data/lib/wx/doc/gen/utils.rb +273 -0
  370. data/lib/wx/doc/gen/v_list_box.rb +272 -0
  371. data/lib/wx/doc/gen/v_scrolled_canvas.rb +195 -0
  372. data/lib/wx/doc/gen/v_scrolled_window.rb +191 -0
  373. data/lib/wx/doc/gen/validator.rb +68 -0
  374. data/lib/wx/doc/gen/variant.rb +294 -0
  375. data/lib/wx/doc/gen/window.rb +2917 -0
  376. data/lib/wx/doc/gen/window_dc.rb +38 -0
  377. data/lib/wx/doc/gen/window_disabler.rb +30 -0
  378. data/lib/wx/doc/gen/with_images.rb +84 -0
  379. data/lib/wx/doc/gen/wizard.rb +257 -0
  380. data/lib/wx/doc/gen/wizard_event.rb +113 -0
  381. data/lib/wx/doc/gen/wizard_page.rb +65 -0
  382. data/lib/wx/doc/gen/wizard_page_simple.rb +88 -0
  383. data/lib/wx/doc/gen/wrap_sizer.rb +79 -0
  384. data/lib/wx/doc/gen/xml_node.rb +316 -0
  385. data/lib/wx/doc/gen/xml_resource.rb +320 -0
  386. data/lib/wx/doc/generic_validator.rb +5 -0
  387. data/lib/wx/doc/pg/pg_property.rb +5 -0
  388. data/lib/wx/doc/tip_window.rb +18 -6
  389. data/lib/wx/doc/variant.rb +30 -0
  390. data/lib/wx/grid/events/evt_list.rb +166 -0
  391. data/lib/wx/html/events/evt_list.rb +27 -0
  392. data/lib/wx/html/simple_html_listbox.rb +46 -33
  393. data/lib/wx/keyword_defs.rb +9 -0
  394. data/lib/wx/pg/events/evt_list.rb +73 -0
  395. data/lib/wx/pg/pg_property.rb +85 -52
  396. data/lib/wx/pg/property_grid_interface.rb +12 -2
  397. data/lib/wx/rbn/events/evt_list.rb +102 -0
  398. data/lib/wx/rtc/events/evt_list.rb +98 -0
  399. data/lib/wx/rtc/ext/rich_text_ctrl.rb +24 -0
  400. data/lib/wx/stc/events/evt_list.rb +178 -0
  401. data/lib/wx/version.rb +1 -1
  402. data/lib/wx/wxruby/cmd/setup.rb +6 -0
  403. data/rakelib/configure.rb +9 -0
  404. data/rakelib/gem.rake +84 -66
  405. data/rakelib/gem.rb +4 -20
  406. data/rakelib/lib/config/linux.rb +1 -1
  407. data/rakelib/lib/config/macosx.rb +15 -1
  408. data/rakelib/lib/config/pkgman/linux.rb +7 -2
  409. data/rakelib/lib/config/unixish.rb +3 -3
  410. data/rakelib/lib/config.rb +19 -8
  411. data/rakelib/lib/core/include/swigdirector.inc +3 -3
  412. data/rakelib/lib/core/include/swigrubyerrors.inc +4 -8
  413. data/rakelib/lib/core/include/swigrubyrun.inc +20 -4
  414. data/rakelib/lib/core/include/swigrun.inc +189 -0
  415. data/rakelib/lib/core/package.rb +3 -1
  416. data/rakelib/lib/core/spec.rb +1 -1
  417. data/rakelib/lib/director/accelerator.rb +1 -1
  418. data/rakelib/lib/director/animation.rb +1 -0
  419. data/rakelib/lib/director/app_traits.rb +1 -1
  420. data/rakelib/lib/director/aui_manager.rb +21 -14
  421. data/rakelib/lib/director/aui_mdi_child_frame.rb +2 -0
  422. data/rakelib/lib/director/aui_mdi_parent_frame.rb +4 -0
  423. data/rakelib/lib/director/aui_notebook.rb +20 -3
  424. data/rakelib/lib/director/aui_tab_ctrl.rb +64 -106
  425. data/rakelib/lib/director/bitmap_combobox.rb +4 -2
  426. data/rakelib/lib/director/calendar_ctrl.rb +72 -14
  427. data/rakelib/lib/director/clipboard.rb +2 -0
  428. data/rakelib/lib/director/data_object.rb +15 -7
  429. data/rakelib/lib/director/date_picker_ctrl.rb +4 -1
  430. data/rakelib/lib/director/display.rb +81 -0
  431. data/rakelib/lib/director/event.rb +33 -16
  432. data/rakelib/lib/director/event_handler.rb +27 -2
  433. data/rakelib/lib/director/functions.rb +9 -0
  434. data/rakelib/lib/director/geometry.rb +5 -0
  435. data/rakelib/lib/director/grid_ctrl.rb +123 -28
  436. data/rakelib/lib/director/help_provider.rb +1 -1
  437. data/rakelib/lib/director/html_listbox.rb +30 -4
  438. data/rakelib/lib/director/hvscrolled.rb +154 -0
  439. data/rakelib/lib/director/image_list.rb +1 -0
  440. data/rakelib/lib/director/mdi_frame.rb +4 -0
  441. data/rakelib/lib/director/menu.rb +56 -15
  442. data/rakelib/lib/director/menu_bar.rb +62 -0
  443. data/rakelib/lib/director/menu_item.rb +7 -1
  444. data/rakelib/lib/director/num_validator.rb +27 -0
  445. data/rakelib/lib/director/numeric_property_validator.rb +9 -0
  446. data/rakelib/lib/director/persistent_window.rb +16 -0
  447. data/rakelib/lib/director/pgproperty.rb +3 -2
  448. data/rakelib/lib/director/popup_window.rb +2 -0
  449. data/rakelib/lib/director/preview_frame.rb +29 -6
  450. data/rakelib/lib/director/printer.rb +59 -5
  451. data/rakelib/lib/director/property_grid.rb +37 -18
  452. data/rakelib/lib/director/property_grid_interface.rb +10 -8
  453. data/rakelib/lib/director/property_grid_manager.rb +99 -39
  454. data/rakelib/lib/director/property_grid_page.rb +60 -0
  455. data/rakelib/lib/director/rich_tooltip.rb +22 -0
  456. data/rakelib/lib/director/richtext_ctrl.rb +5 -0
  457. data/rakelib/lib/director/richtext_object.rb +13 -4
  458. data/rakelib/lib/director/richtext_style_listbox.rb +11 -2
  459. data/rakelib/lib/director/scrolled_t.rb +3 -0
  460. data/rakelib/lib/director/searchctrl.rb +1 -0
  461. data/rakelib/lib/director/task_bar_icon.rb +14 -8
  462. data/rakelib/lib/director/text_validator.rb +9 -0
  463. data/rakelib/lib/director/tip_window.rb +117 -6
  464. data/rakelib/lib/director/tool_bar.rb +6 -0
  465. data/rakelib/lib/director/top_level_window.rb +0 -1
  466. data/rakelib/lib/director/utils.rb +3 -1
  467. data/rakelib/lib/director/validator.rb +12 -0
  468. data/rakelib/lib/director/variant.rb +64 -20
  469. data/rakelib/lib/director/vlistbox.rb +29 -22
  470. data/rakelib/lib/director/window.rb +12 -2
  471. data/rakelib/lib/director/xml_resource.rb +6 -0
  472. data/rakelib/lib/generate/doc/aui_manager.yaml +1 -1
  473. data/rakelib/lib/generate/doc/rich_tool_tip.yaml +26 -0
  474. data/rakelib/lib/generate/doc.rb +12 -7
  475. data/rakelib/lib/generate/interface.rb +16 -1
  476. data/rakelib/lib/specs/interfaces.rb +6 -2
  477. data/rakelib/lib/swig_runner.rb +12 -12
  478. data/rakelib/lib/typemap/aui_tabctrl.rb +46 -0
  479. data/rakelib/lib/typemap/common.rb +3 -3
  480. data/rakelib/lib/typemap/print_page_range.rb +32 -8
  481. data/samples/art/wxruby-512x512.png +0 -0
  482. data/samples/calendar/calendar.rb +64 -1
  483. data/samples/dialogs/dialogs.rb +172 -0
  484. data/samples/dialogs/tip.xpm +157 -0
  485. data/samples/drawing/maths_images.rb +1 -1
  486. data/samples/event/event.rb +1 -1
  487. data/samples/printing/printing2.rb +1 -1
  488. data/samples/sampler.rb +26 -8
  489. data/samples/text/textctrl.rb +2 -2
  490. data/samples/treectrl/treectrl.rb +2 -2
  491. data/tests/lib/leaked_process_event_exception_test.rb +1 -1
  492. data/tests/lib/leaked_queued_event_exception_test.rb +1 -1
  493. data/tests/lib/wxapp_runner.rb +31 -41
  494. data/tests/lib/wxframe_runner.rb +23 -11
  495. data/tests/lib/wxrb_test.rb +58 -0
  496. data/tests/test_app_event_filter.rb +1 -1
  497. data/tests/test_app_exit_exception.rb +3 -3
  498. data/tests/test_app_init_exception.rb +3 -3
  499. data/tests/test_app_traits.rb +24 -21
  500. data/tests/test_art.rb +7 -7
  501. data/tests/test_art_provider.rb +1 -1
  502. data/tests/test_basic.rb +2 -2
  503. data/tests/test_book_controls.rb +1 -1
  504. data/tests/test_box_sizer.rb +1 -1
  505. data/tests/test_clipboard.rb +5 -5
  506. data/tests/test_combo_ctrl.rb +2 -2
  507. data/tests/test_config.rb +11 -1
  508. data/tests/test_dc.rb +1 -1
  509. data/tests/test_dialog.rb +1 -1
  510. data/tests/test_event_handling.rb +1 -1
  511. data/tests/test_events.rb +1 -1
  512. data/tests/test_exceptions.rb +2 -2
  513. data/tests/test_ext_controls.rb +10 -10
  514. data/tests/test_file_dialog.rb +1 -1
  515. data/tests/test_font.rb +1 -1
  516. data/tests/test_gdi_object.rb +1 -1
  517. data/tests/test_geometry.rb +2 -2
  518. data/tests/test_grid_sizer.rb +2 -2
  519. data/tests/test_intl.rb +1 -1
  520. data/tests/test_item_data.rb +12 -12
  521. data/tests/test_list_ctrl.rb +1 -1
  522. data/tests/test_log.rb +2 -2
  523. data/tests/test_media_ctrl.rb +1 -1
  524. data/tests/test_menu.rb +114 -43
  525. data/tests/test_proof_check.rb +1 -1
  526. data/tests/test_propgrid.rb +857 -0
  527. data/tests/test_richtext.rb +10 -24
  528. data/tests/test_secret_store.rb +1 -1
  529. data/tests/test_sizer.rb +1 -1
  530. data/tests/test_std_controls.rb +8 -8
  531. data/tests/test_styled_text_ctrl.rb +1 -1
  532. data/tests/test_timer.rb +1 -1
  533. data/tests/test_tree_ctrl.rb +1 -1
  534. data/tests/test_validators.rb +79 -36
  535. data/tests/test_variant.rb +1 -1
  536. data/tests/test_window.rb +11 -11
  537. data/tests/testapp.rb +2 -2
  538. data/tests/testapp_noframe.rb +2 -2
  539. metadata +402 -12
  540. data/lib/wx/aui/aui_tab_ctrl.rb +0 -18
  541. data/rakelib/lib/director/hvscrolled_window.rb +0 -140
@@ -0,0 +1,2829 @@
1
+ # :stopdoc:
2
+ # This file is automatically generated by the WXRuby3 documentation
3
+ # generator. Do not alter this file.
4
+ # :startdoc:
5
+
6
+
7
+ module Wx
8
+
9
+ module PG
10
+
11
+ # Basic property with boolean value.
12
+ #
13
+ # <b>Supported special attributes:</b>
14
+ #
15
+ # - {Wx::PG::PG_BOOL_USE_CHECKBOX}: Set to true to use check box editor instead of combo box.
16
+ # - {Wx::PG::PG_BOOL_USE_DOUBLE_CLICK_CYCLING}: Set to true to cycle combo box instead showing the list.
17
+ #
18
+ # @wxrb_require USE_PROPGRID
19
+ class BoolProperty < PGProperty
20
+
21
+ # @param label [String]
22
+ # @param name [String]
23
+ # @param value [Boolean]
24
+ # @return [Wx::PG::BoolProperty]
25
+ def initialize(label=Wx::PG::PG_LABEL, name=Wx::PG::PG_LABEL, value=false) end
26
+
27
+ # Converts property value into a text representation.
28
+ #
29
+ # <div class="wxrb-remark">
30
+ # <b>Remark:</b>
31
+ # <p>Default implementation calls {Wx::PG::BoolProperty#generate_composed_value}.
32
+ # </p>
33
+ # </div>
34
+ # @param value [Wx::Variant] Value to be converted.
35
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::Null} (default value), then displayed string is returned. If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable string value instead of displayable. If {Wx::PG::PGPropValFormatFlags::EditableValue} is set, returns string value that must be editable in textctrl. If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, returns text that is appropriate to display as a part of string property's composite text representation.
36
+ # @return [String]
37
+ def value_to_string(value, flags=PGPropValFormatFlags::Null) end
38
+
39
+ # Converts text into {Wx::Variant} value appropriate for this property.
40
+ #
41
+ # Returns true if resulting {Wx::Variant} value was different.
42
+ #
43
+ # <div class="wxrb-remark">
44
+ # <b>Remark:</b>
45
+ # <p>Default implementation converts semicolon delimited tokens into child values. Only works for properties with children.
46
+ # </p>
47
+ # </div>
48
+ #
49
+ # You might want to take into account that m_value is Null variant if property value is unspecified (which is usually only case if you explicitly enabled that sort behaviour).
50
+ # @param variant [Wx::Variant] On function entry this is the old value (should not be null {Wx::Variant} in normal cases). Translated value must be assigned back to it.
51
+ # @param text [String] Text to be translated into variant.
52
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable value instead of displayable one (they may be different). If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, text is interpreted as a part of composite property string value (as generated by {Wx::PG::BoolProperty#value_to_string} called with this same flag).
53
+ # @return [Boolean]
54
+ def string_to_value(variant, text, flags=PGPropValFormatFlags::Null) end
55
+
56
+ # Converts integer (possibly a choice selection) into {Wx::Variant} value appropriate for this property.
57
+ #
58
+ # Returns true if resulting {Wx::Variant} value was different.
59
+ #
60
+ # <div class="wxrb-remark">
61
+ # <b>Remark:</b>
62
+ # <p>
63
+ #
64
+ # - If property is not supposed to use choice or spinctrl or other editor with int-based value, it is not necessary to implement this method.
65
+ # - Default implementation simply assign given int to m_value.
66
+ # - If property uses choice control, and displays a dialog on some choice items, then it is preferred to display that dialog in IntToValue instead of OnEvent.
67
+ # - You might want to take into account that m_value is Mull variant if property value is unspecified (which is usually only case if you explicitly enabled that sort behaviour).
68
+ #
69
+ # </p>
70
+ # </div>
71
+ # @param variant [Wx::Variant] On function entry this is the old value (should not be null {Wx::Variant} in normal cases). Translated value must be assigned back to it.
72
+ # @param number [Integer] Integer to be translated into variant.
73
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable value instead of displayable one.
74
+ # @return [Boolean]
75
+ def int_to_value(variant, number, flags=PGPropValFormatFlags::Null) end
76
+
77
+ # Reimplement this member function to add special handling for attributes of this property.
78
+ #
79
+ # Return false to have the attribute automatically stored in m_attributes. Default implementation simply does that and nothing else.
80
+ #
81
+ # <div class="wxrb-remark">
82
+ # <b>Remark:</b>
83
+ # <p>To actually set property attribute values from the application, use {Wx::PG::PGProperty#set_attribute} instead.
84
+ # </p>
85
+ # </div>
86
+ # @param name [String]
87
+ # @param value [Wx::Variant]
88
+ # @return [Boolean]
89
+ def do_set_attribute(name, value) end
90
+
91
+ #
92
+ # @return [Wx::Variant]
93
+ def value_; end
94
+ #
95
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
96
+ # @return [void]
97
+ def value_=(val); end
98
+
99
+ end # BoolProperty
100
+
101
+ # Property representing {Wx::DateTime}.
102
+ #
103
+ # <b>Supported special attributes:</b>
104
+ #
105
+ # - {Wx::PG::PG_DATE_FORMAT}: Determines displayed date format.
106
+ # - {Wx::PG::PG_DATE_PICKER_STYLE}: Determines window style used with {Wx::DatePickerCtrl}. Default is {Wx::DP_DEFAULT} | {Wx::DP_SHOWCENTURY}. Using {Wx::DP_ALLOWNONE} enables additional support for unspecified property value.
107
+ #
108
+ # @wxrb_require USE_PROPGRID
109
+ class DateProperty < PGProperty
110
+
111
+ # @param label [String]
112
+ # @param name [String]
113
+ # @param value [Time,Date,DateTime]
114
+ # @return [Wx::PG::DateProperty]
115
+ def initialize(label=Wx::PG::PG_LABEL, name=Wx::PG::PG_LABEL, value=(Wx::DateTime.new())) end
116
+
117
+ # This virtual function is called after m_value has been set.
118
+ #
119
+ # <div class="wxrb-remark">
120
+ # <b>Remark:</b>
121
+ # <p>
122
+ #
123
+ # - If m_value was set to Null variant (i.e. unspecified value), {Wx::PG::DateProperty#on_set_value} will not be called.
124
+ # - m_value may be of any variant type. Typically properties internally support only one variant type, and as such {Wx::PG::DateProperty#on_set_value} provides a good opportunity to convert supported values into internal type.
125
+ # - Default implementation does nothing.
126
+ #
127
+ # </p>
128
+ # </div>
129
+ # @return [void]
130
+ def on_set_value; end
131
+
132
+ # Converts property value into a text representation.
133
+ #
134
+ # <div class="wxrb-remark">
135
+ # <b>Remark:</b>
136
+ # <p>Default implementation calls {Wx::PG::DateProperty#generate_composed_value}.
137
+ # </p>
138
+ # </div>
139
+ # @param value [Wx::Variant] Value to be converted.
140
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::Null} (default value), then displayed string is returned. If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable string value instead of displayable. If {Wx::PG::PGPropValFormatFlags::EditableValue} is set, returns string value that must be editable in textctrl. If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, returns text that is appropriate to display as a part of string property's composite text representation.
141
+ # @return [String]
142
+ def value_to_string(value, flags=PGPropValFormatFlags::Null) end
143
+
144
+ # Converts text into {Wx::Variant} value appropriate for this property.
145
+ #
146
+ # Returns true if resulting {Wx::Variant} value was different.
147
+ #
148
+ # <div class="wxrb-remark">
149
+ # <b>Remark:</b>
150
+ # <p>Default implementation converts semicolon delimited tokens into child values. Only works for properties with children.
151
+ # </p>
152
+ # </div>
153
+ #
154
+ # You might want to take into account that m_value is Null variant if property value is unspecified (which is usually only case if you explicitly enabled that sort behaviour).
155
+ # @param variant [Wx::Variant] On function entry this is the old value (should not be null {Wx::Variant} in normal cases). Translated value must be assigned back to it.
156
+ # @param text [String] Text to be translated into variant.
157
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable value instead of displayable one (they may be different). If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, text is interpreted as a part of composite property string value (as generated by {Wx::PG::DateProperty#value_to_string} called with this same flag).
158
+ # @return [Boolean]
159
+ def string_to_value(variant, text, flags=PGPropValFormatFlags::Null) end
160
+
161
+ # Reimplement this member function to add special handling for attributes of this property.
162
+ #
163
+ # Return false to have the attribute automatically stored in m_attributes. Default implementation simply does that and nothing else.
164
+ #
165
+ # <div class="wxrb-remark">
166
+ # <b>Remark:</b>
167
+ # <p>To actually set property attribute values from the application, use {Wx::PG::PGProperty#set_attribute} instead.
168
+ # </p>
169
+ # </div>
170
+ # @param name [String]
171
+ # @param value [Wx::Variant]
172
+ # @return [Boolean]
173
+ def do_set_attribute(name, value) end
174
+
175
+ # @param format [String]
176
+ # @return [void]
177
+ def set_format(format) end
178
+ alias_method :format=, :set_format
179
+
180
+ # @return [Wx::String]
181
+ def get_format; end
182
+ alias_method :format, :get_format
183
+
184
+ # @param dt [Time,Date,DateTime]
185
+ # @return [void]
186
+ def set_date_value(dt) end
187
+ alias_method :date_value=, :set_date_value
188
+
189
+ # @return [Time,Date,DateTime]
190
+ def get_date_value; end
191
+ alias_method :date_value, :get_date_value
192
+
193
+ # @return [Integer]
194
+ def get_date_picker_style; end
195
+ alias_method :date_picker_style, :get_date_picker_style
196
+
197
+ #
198
+ #
199
+ #
200
+ # @return [String]
201
+ def format_; end
202
+ #
203
+ #
204
+ #
205
+ # @param val [String]
206
+ # @return [void]
207
+ def format_=(val); end
208
+
209
+ #
210
+ #
211
+ #
212
+ # @return [Integer]
213
+ def dp_style_; end
214
+ #
215
+ #
216
+ #
217
+ # @param val [Integer]
218
+ # @return [void]
219
+ def dp_style_=(val); end
220
+
221
+ #
222
+ # @return [Wx::Variant]
223
+ def value_; end
224
+ #
225
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
226
+ # @return [void]
227
+ def value_=(val); end
228
+
229
+ end # DateProperty
230
+
231
+ # Represents a bit set that fits in a long integer.
232
+ #
233
+ # {Wx::PG::BoolProperty} sub-properties are created for editing individual bits. Textctrl is created to manually edit the flags as a text; a continuous sequence of spaces, commas and semicolons is considered as a flag id separator. <b>Note:</b> When changing "choices" (ie. flag labels) of {Wx::PG::FlagsProperty}, you will need to use SetPropertyChoices - otherwise they will not get updated properly.
234
+ #
235
+ # @wxrb_require USE_PROPGRID
236
+ class FlagsProperty < PGProperty
237
+
238
+ # @overload initialize(label, name, choices, value=0)
239
+ # @param label [String]
240
+ # @param name [String]
241
+ # @param choices [Wx::PG::PGChoices]
242
+ # @param value [Integer]
243
+ # @return [Wx::PG::FlagsProperty]
244
+ # @overload initialize(label=Wx::PG::PG_LABEL, name=Wx::PG::PG_LABEL, labels=(Wx::ArrayString.new()), values=(Wx::ArrayInt.new()), value=0)
245
+ # @param label [String]
246
+ # @param name [String]
247
+ # @param labels [Array<String>]
248
+ # @param values [Array<Integer>]
249
+ # @param value [Integer]
250
+ # @return [Wx::PG::FlagsProperty]
251
+ def initialize(*args) end
252
+
253
+ # This virtual function is called after m_value has been set.
254
+ #
255
+ # <div class="wxrb-remark">
256
+ # <b>Remark:</b>
257
+ # <p>
258
+ #
259
+ # - If m_value was set to Null variant (i.e. unspecified value), {Wx::PG::FlagsProperty#on_set_value} will not be called.
260
+ # - m_value may be of any variant type. Typically properties internally support only one variant type, and as such {Wx::PG::FlagsProperty#on_set_value} provides a good opportunity to convert supported values into internal type.
261
+ # - Default implementation does nothing.
262
+ #
263
+ # </p>
264
+ # </div>
265
+ # @return [void]
266
+ def on_set_value; end
267
+
268
+ # Converts property value into a text representation.
269
+ #
270
+ # <div class="wxrb-remark">
271
+ # <b>Remark:</b>
272
+ # <p>Default implementation calls {Wx::PG::FlagsProperty#generate_composed_value}.
273
+ # </p>
274
+ # </div>
275
+ # @param value [Wx::Variant] Value to be converted.
276
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::Null} (default value), then displayed string is returned. If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable string value instead of displayable. If {Wx::PG::PGPropValFormatFlags::EditableValue} is set, returns string value that must be editable in textctrl. If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, returns text that is appropriate to display as a part of string property's composite text representation.
277
+ # @return [String]
278
+ def value_to_string(value, flags=PGPropValFormatFlags::Null) end
279
+
280
+ # Converts text into {Wx::Variant} value appropriate for this property.
281
+ #
282
+ # Returns true if resulting {Wx::Variant} value was different.
283
+ #
284
+ # <div class="wxrb-remark">
285
+ # <b>Remark:</b>
286
+ # <p>Default implementation converts semicolon delimited tokens into child values. Only works for properties with children.
287
+ # </p>
288
+ # </div>
289
+ #
290
+ # You might want to take into account that m_value is Null variant if property value is unspecified (which is usually only case if you explicitly enabled that sort behaviour).
291
+ # @param variant [Wx::Variant] On function entry this is the old value (should not be null {Wx::Variant} in normal cases). Translated value must be assigned back to it.
292
+ # @param text [String] Text to be translated into variant.
293
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable value instead of displayable one (they may be different). If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, text is interpreted as a part of composite property string value (as generated by {Wx::PG::FlagsProperty#value_to_string} called with this same flag).
294
+ # @return [Boolean]
295
+ def string_to_value(variant, text, flags) end
296
+
297
+ # Called after value of a child property has been altered.
298
+ #
299
+ # Must return new value of the whole property (after any alterations warranted by child's new value).
300
+ # Note that this function is usually called at the time that value of this property, or given child property, is still pending for change, and as such, result of {Wx::PG::FlagsProperty#get_value} or m_value should not be relied on.
301
+ # Sample pseudo-code implementation:
302
+ #
303
+ # ```ruby
304
+ # class MyProperty < Wx::PG::FlagsProperty
305
+ #
306
+ # def child_changed(thisValue, childIndex, childValue)
307
+ # # Acquire reference to actual type of data stored in variant
308
+ # flags = thisValue.object;
309
+ # case childIndex
310
+ # when 0
311
+ # flags.sub_prop1 = childValue.to_i
312
+ # when 1
313
+ # flags.sub_prop2 = childValue.to_s
314
+ # # ...
315
+ # end
316
+ # # return altered data
317
+ # Wx::Variant.new(flags)
318
+ # end
319
+ #
320
+ # end
321
+ # ```
322
+ #
323
+ # Modified value of the whole property.
324
+ # @param thisValue [Wx::Variant] Value of this property. Changed value should be returned (in previous versions of {Wx::PG::PropertyGrid} it was only necessary to write value back to this argument).
325
+ # @param childIndex [Integer] Index of child changed (you can use Item(childIndex) to get child property).
326
+ # @param childValue [Wx::Variant] (Pending) value of the child property.
327
+ # @return [Wx::Variant]
328
+ def child_changed(thisValue, childIndex, childValue) end
329
+
330
+ # Refresh values of child properties.
331
+ #
332
+ # Automatically called after value is set.
333
+ # @return [void]
334
+ def refresh_children; end
335
+
336
+ # Reimplement this member function to add special handling for attributes of this property.
337
+ #
338
+ # Return false to have the attribute automatically stored in m_attributes. Default implementation simply does that and nothing else.
339
+ #
340
+ # <div class="wxrb-remark">
341
+ # <b>Remark:</b>
342
+ # <p>To actually set property attribute values from the application, use {Wx::PG::PGProperty#set_attribute} instead.
343
+ # </p>
344
+ # </div>
345
+ # @param name [String]
346
+ # @param value [Wx::Variant]
347
+ # @return [Boolean]
348
+ def do_set_attribute(name, value) end
349
+
350
+ # Returns which choice is currently selected.
351
+ #
352
+ # Only applies to properties which have choices.
353
+ # Needs to reimplemented in derived class if property value does not map directly to a choice. Integer as index, bool, and string usually do.
354
+ # @return [Integer]
355
+ def get_choice_selection; end
356
+ alias_method :choice_selection, :get_choice_selection
357
+
358
+ # @return [Integer]
359
+ def get_item_count; end
360
+ alias_method :item_count, :get_item_count
361
+
362
+ # @param ind [Integer]
363
+ # @return [Wx::String]
364
+ def get_item_label(ind) end
365
+ alias_method :item_label, :get_item_label
366
+
367
+ #
368
+ # @return [Wx::Variant]
369
+ def value_; end
370
+ #
371
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
372
+ # @return [void]
373
+ def value_=(val); end
374
+
375
+ end # FlagsProperty
376
+
377
+ # Basic property with string value.
378
+ #
379
+ # <b>Supported special attributes:</b>
380
+ #
381
+ # - {Wx::PG::PG_STRING_PASSWORD}: set to true in order to enable {Wx::TE_PASSWORD} on the editor.
382
+ #
383
+ # <div class="wxrb-remark">
384
+ # <b>Remark:</b>
385
+ # <p>
386
+ #
387
+ # - If value "<composed>" is set, then actual value is formed (or composed) from values of child properties.
388
+ #
389
+ # </p>
390
+ # </div>
391
+ #
392
+ # @wxrb_require USE_PROPGRID
393
+ class StringProperty < PGProperty
394
+
395
+ # @param label [String]
396
+ # @param name [String]
397
+ # @param value [String]
398
+ # @return [Wx::PG::StringProperty]
399
+ def initialize(label=Wx::PG::PG_LABEL, name=Wx::PG::PG_LABEL, value=('')) end
400
+
401
+ # Converts property value into a text representation.
402
+ #
403
+ # <div class="wxrb-remark">
404
+ # <b>Remark:</b>
405
+ # <p>Default implementation calls {Wx::PG::StringProperty#generate_composed_value}.
406
+ # </p>
407
+ # </div>
408
+ # @param value [Wx::Variant] Value to be converted.
409
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::Null} (default value), then displayed string is returned. If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable string value instead of displayable. If {Wx::PG::PGPropValFormatFlags::EditableValue} is set, returns string value that must be editable in textctrl. If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, returns text that is appropriate to display as a part of string property's composite text representation.
410
+ # @return [String]
411
+ def value_to_string(value, flags=PGPropValFormatFlags::Null) end
412
+
413
+ # Converts text into {Wx::Variant} value appropriate for this property.
414
+ #
415
+ # Returns true if resulting {Wx::Variant} value was different.
416
+ #
417
+ # <div class="wxrb-remark">
418
+ # <b>Remark:</b>
419
+ # <p>Default implementation converts semicolon delimited tokens into child values. Only works for properties with children.
420
+ # </p>
421
+ # </div>
422
+ #
423
+ # You might want to take into account that m_value is Null variant if property value is unspecified (which is usually only case if you explicitly enabled that sort behaviour).
424
+ # @param variant [Wx::Variant] On function entry this is the old value (should not be null {Wx::Variant} in normal cases). Translated value must be assigned back to it.
425
+ # @param text [String] Text to be translated into variant.
426
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable value instead of displayable one (they may be different). If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, text is interpreted as a part of composite property string value (as generated by {Wx::PG::StringProperty#value_to_string} called with this same flag).
427
+ # @return [Boolean]
428
+ def string_to_value(variant, text, flags=PGPropValFormatFlags::Null) end
429
+
430
+ # Reimplement this member function to add special handling for attributes of this property.
431
+ #
432
+ # Return false to have the attribute automatically stored in m_attributes. Default implementation simply does that and nothing else.
433
+ #
434
+ # <div class="wxrb-remark">
435
+ # <b>Remark:</b>
436
+ # <p>To actually set property attribute values from the application, use {Wx::PG::PGProperty#set_attribute} instead.
437
+ # </p>
438
+ # </div>
439
+ # @param name [String]
440
+ # @param value [Wx::Variant]
441
+ # @return [Boolean]
442
+ def do_set_attribute(name, value) end
443
+
444
+ # This is updated so "<composed>" special value can be handled.
445
+ # @return [void]
446
+ def on_set_value; end
447
+
448
+ #
449
+ # @return [Wx::Variant]
450
+ def value_; end
451
+ #
452
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
453
+ # @return [void]
454
+ def value_=(val); end
455
+
456
+ end # StringProperty
457
+
458
+ # Category (caption) property.
459
+ #
460
+ #
461
+ #
462
+ # @wxrb_require USE_PROPGRID
463
+ class PropertyCategory < PGProperty
464
+
465
+ # @overload initialize()
466
+ # Default constructor is only used in special cases.
467
+ # @return [Wx::PG::PropertyCategory]
468
+ # @overload initialize(label, name=Wx::PG::PG_LABEL)
469
+ # @param label [String]
470
+ # @param name [String]
471
+ # @return [Wx::PG::PropertyCategory]
472
+ def initialize(*args) end
473
+
474
+ # @param wnd [Wx::Window]
475
+ # @param font [Wx::Font,Wx::FontInfo]
476
+ # @return [Integer]
477
+ def get_text_extent(wnd, font) end
478
+ alias_method :text_extent, :get_text_extent
479
+
480
+ # Converts property value into a text representation.
481
+ #
482
+ # <div class="wxrb-remark">
483
+ # <b>Remark:</b>
484
+ # <p>Default implementation calls {Wx::PG::PropertyCategory#generate_composed_value}.
485
+ # </p>
486
+ # </div>
487
+ # @param value [Wx::Variant] Value to be converted.
488
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::Null} (default value), then displayed string is returned. If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable string value instead of displayable. If {Wx::PG::PGPropValFormatFlags::EditableValue} is set, returns string value that must be editable in textctrl. If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, returns text that is appropriate to display as a part of string property's composite text representation.
489
+ # @return [String]
490
+ def value_to_string(value, flags) end
491
+
492
+ # Returns text representation of property's value.
493
+ #
494
+ # <div class="wxrb-remark">
495
+ # <b>Remark:</b>
496
+ # <p>In older versions, this function used to be overridden to convert property's value into a string representation. This function is now handled by {Wx::PG::PropertyCategory#value_to_string}, and overriding this function now will result in run-time assertion failure.
497
+ # </p>
498
+ # </div>
499
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::Null} (default value), then displayed string is returned. If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable string value instead of displayable. If {Wx::PG::PGPropValFormatFlags::EditableValue} is set, returns string value that must be editable in textctrl. If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, returns text that is appropriate to display as a part of string property's composite text representation.
500
+ # @return [String]
501
+ def get_value_as_string(flags=PGPropValFormatFlags::Null) end
502
+ alias_method :value_as_string, :get_value_as_string
503
+
504
+ #
505
+ # @return [Wx::Variant]
506
+ def value_; end
507
+ #
508
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
509
+ # @return [void]
510
+ def value_=(val); end
511
+
512
+ end # PropertyCategory
513
+
514
+ # This is an abstract class which serves as a base class for the properties having a button triggering an editor dialog, like e.g.
515
+ #
516
+ # {Wx::PG::LongStringProperty}, {Wx::PG::DirProperty}, {Wx::PG::FileProperty}.
517
+ # <b>Supported special attributes:</b>
518
+ #
519
+ # - {Wx::PG::PG_DIALOG_TITLE}: Sets a specific title for the editor dialog.
520
+ #
521
+ # @wxrb_require USE_PROPGRID
522
+ class EditorDialogProperty < PGProperty
523
+
524
+ # Returns instance of a new {Wx::PG::PGEditorDialogAdapter} instance, which is used when user presses the (optional) button next to the editor control;.
525
+ #
526
+ # Default implementation returns nil (i.e. no action is generated when button is pressed).
527
+ # @return [Wx::PG::PGEditorDialogAdapter]
528
+ def get_editor_dialog; end
529
+ alias_method :editor_dialog, :get_editor_dialog
530
+
531
+ # Reimplement this member function to add special handling for attributes of this property.
532
+ #
533
+ # Return false to have the attribute automatically stored in m_attributes. Default implementation simply does that and nothing else.
534
+ #
535
+ # <div class="wxrb-remark">
536
+ # <b>Remark:</b>
537
+ # <p>To actually set property attribute values from the application, use {Wx::PG::PGProperty#set_attribute} instead.
538
+ # </p>
539
+ # </div>
540
+ # @param name [String]
541
+ # @param value [Wx::Variant]
542
+ # @return [Boolean]
543
+ def do_set_attribute(name, value) end
544
+
545
+ #
546
+ #
547
+ #
548
+ # @return [String]
549
+ def dlg_title_; end
550
+ #
551
+ #
552
+ #
553
+ # @param val [String]
554
+ # @return [void]
555
+ def dlg_title_=(val); end
556
+
557
+ #
558
+ #
559
+ #
560
+ # @return [Integer]
561
+ def dlg_style_; end
562
+ #
563
+ #
564
+ #
565
+ # @param val [Integer]
566
+ # @return [void]
567
+ def dlg_style_=(val); end
568
+
569
+ #
570
+ # @return [Wx::Variant]
571
+ def value_; end
572
+ #
573
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
574
+ # @return [void]
575
+ def value_=(val); end
576
+
577
+
578
+ protected
579
+
580
+ # Constructor is protected because {Wx::PG::EditorDialogProperty} is only the base class for other property classes.
581
+ # @param label [String]
582
+ # @param name [String]
583
+ # @return [Wx::PG::EditorDialogProperty]
584
+ def initialize(label, name) end
585
+
586
+ # Shows editor dialog.
587
+ #
588
+ # Value to be edited should be read from value, and if dialog is not cancelled, it should be stored back and true should be returned.
589
+ #
590
+ # Returns true if editor dialog was not cancelled and value was updated.
591
+ # @param pg [Wx::PG::PropertyGrid] Property grid in which property is displayed.
592
+ # @param value [Wx::Variant] Value to be edited.
593
+ # @return [Boolean]
594
+ def display_editor_dialog(pg, value) end
595
+
596
+ end # EditorDialogProperty
597
+
598
+ # Property that manages a list of strings.
599
+ #
600
+ # <b>Supported special attributes:</b>
601
+ #
602
+ # - {Wx::PG::PG_ARRAY_DELIMITER}: Sets string delimiter character.
603
+ # - {Wx::PG::PG_DIALOG_TITLE}: Sets a specific title for the editor dialog (since 3.1.3).
604
+ #
605
+ # @wxrb_require USE_PROPGRID
606
+ class ArrayStringProperty < EditorDialogProperty
607
+
608
+ #
609
+ #
610
+ #
611
+ #
612
+ # @wxrb_require USE_PROPGRID
613
+ class ConversionFlags < Wx::Enum
614
+
615
+ #
616
+ #
617
+ Escape = Wx::PG::ArrayStringProperty::ConversionFlags.new(1)
618
+
619
+ #
620
+ #
621
+ QuoteStrings = Wx::PG::ArrayStringProperty::ConversionFlags.new(2)
622
+
623
+ end # ConversionFlags
624
+
625
+ # @param label [String]
626
+ # @param name [String]
627
+ # @param value [Array<String>]
628
+ # @return [Wx::PG::ArrayStringProperty]
629
+ def initialize(label=Wx::PG::PG_LABEL, name=Wx::PG::PG_LABEL, value=(Wx::ArrayString.new())) end
630
+
631
+ # This virtual function is called after m_value has been set.
632
+ #
633
+ # <div class="wxrb-remark">
634
+ # <b>Remark:</b>
635
+ # <p>
636
+ #
637
+ # - If m_value was set to Null variant (i.e. unspecified value), {Wx::PG::ArrayStringProperty#on_set_value} will not be called.
638
+ # - m_value may be of any variant type. Typically properties internally support only one variant type, and as such {Wx::PG::ArrayStringProperty#on_set_value} provides a good opportunity to convert supported values into internal type.
639
+ # - Default implementation does nothing.
640
+ #
641
+ # </p>
642
+ # </div>
643
+ # @return [void]
644
+ def on_set_value; end
645
+
646
+ # Converts property value into a text representation.
647
+ #
648
+ # <div class="wxrb-remark">
649
+ # <b>Remark:</b>
650
+ # <p>Default implementation calls {Wx::PG::ArrayStringProperty#generate_composed_value}.
651
+ # </p>
652
+ # </div>
653
+ # @param value [Wx::Variant] Value to be converted.
654
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::Null} (default value), then displayed string is returned. If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable string value instead of displayable. If {Wx::PG::PGPropValFormatFlags::EditableValue} is set, returns string value that must be editable in textctrl. If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, returns text that is appropriate to display as a part of string property's composite text representation.
655
+ # @return [String]
656
+ def value_to_string(value, flags=PGPropValFormatFlags::Null) end
657
+
658
+ # Converts text into {Wx::Variant} value appropriate for this property.
659
+ #
660
+ # Returns true if resulting {Wx::Variant} value was different.
661
+ #
662
+ # <div class="wxrb-remark">
663
+ # <b>Remark:</b>
664
+ # <p>Default implementation converts semicolon delimited tokens into child values. Only works for properties with children.
665
+ # </p>
666
+ # </div>
667
+ #
668
+ # You might want to take into account that m_value is Null variant if property value is unspecified (which is usually only case if you explicitly enabled that sort behaviour).
669
+ # @param variant [Wx::Variant] On function entry this is the old value (should not be null {Wx::Variant} in normal cases). Translated value must be assigned back to it.
670
+ # @param text [String] Text to be translated into variant.
671
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable value instead of displayable one (they may be different). If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, text is interpreted as a part of composite property string value (as generated by {Wx::PG::ArrayStringProperty#value_to_string} called with this same flag).
672
+ # @return [Boolean]
673
+ def string_to_value(variant, text, flags=PGPropValFormatFlags::Null) end
674
+
675
+ # Reimplement this member function to add special handling for attributes of this property.
676
+ #
677
+ # Return false to have the attribute automatically stored in m_attributes. Default implementation simply does that and nothing else.
678
+ #
679
+ # <div class="wxrb-remark">
680
+ # <b>Remark:</b>
681
+ # <p>To actually set property attribute values from the application, use {Wx::PG::PGProperty#set_attribute} instead.
682
+ # </p>
683
+ # </div>
684
+ # @param name [String]
685
+ # @param value [Wx::Variant]
686
+ # @return [Boolean]
687
+ def do_set_attribute(name, value) end
688
+
689
+ # Implement in derived class for custom array-to-string conversion.
690
+ # @param arr [Array<String>]
691
+ # @param delimiter [String]
692
+ # @return [String]
693
+ def convert_array_to_string(arr, delimiter) end
694
+
695
+ # Shows string editor dialog to edit the individual item.
696
+ #
697
+ # Value to be edited should be read from value, and if dialog is not cancelled, it should be stored back and true should be returned if that was the case.
698
+ # @param parent [Wx::Window]
699
+ # @return [String]
700
+ def on_custom_string_edit(parent) end
701
+
702
+ # Creates {Wx::PG::PGArrayEditorDialog} for string editing.
703
+ # @return [Wx::PG::PGArrayEditorDialog]
704
+ def create_editor_dialog; end
705
+
706
+ # Generates string based on the contents of {Wx::ArrayString} src.
707
+ # @param src [Array<String>]
708
+ # @param delimiter [String]
709
+ # @param flags [Integer]
710
+ # @return [String]
711
+ def self.array_string_to_string(src, delimiter, flags) end
712
+
713
+ #
714
+ #
715
+ #
716
+ # @return [String]
717
+ def display_; end
718
+ #
719
+ #
720
+ #
721
+ # @param val [String]
722
+ # @return [void]
723
+ def display_=(val); end
724
+
725
+ #
726
+ #
727
+ #
728
+ # @return [String]
729
+ def delimiter_; end
730
+ #
731
+ #
732
+ #
733
+ # @param val [String]
734
+ # @return [void]
735
+ def delimiter_=(val); end
736
+
737
+ #
738
+ #
739
+ #
740
+ # @return [String]
741
+ def custom_btn_text_; end
742
+ #
743
+ #
744
+ #
745
+ # @param val [String]
746
+ # @return [void]
747
+ def custom_btn_text_=(val); end
748
+
749
+ #
750
+ # @return [Wx::Variant]
751
+ def value_; end
752
+ #
753
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
754
+ # @return [void]
755
+ def value_=(val); end
756
+
757
+
758
+ protected
759
+
760
+ # Shows editor dialog.
761
+ #
762
+ # Value to be edited should be read from value, and if dialog is not cancelled, it should be stored back and true should be returned.
763
+ #
764
+ # Returns true if editor dialog was not cancelled and value was updated.
765
+ # @param pg [Wx::PG::PropertyGrid] Property grid in which property is displayed.
766
+ # @param value [Wx::Variant] Value to be edited.
767
+ # @return [Boolean]
768
+ def display_editor_dialog(pg, value) end
769
+
770
+ end # ArrayStringProperty
771
+
772
+ # Like {Wx::PG::LongStringProperty}, but the button triggers directory selector instead.
773
+ #
774
+ # <b>Supported special attributes:</b>
775
+ #
776
+ # - {Wx::PG::PG_DIALOG_TITLE}: Sets a specific title for the file dialog (since 3.1.3).
777
+ #
778
+ # @wxrb_require USE_PROPGRID
779
+ class DirProperty < EditorDialogProperty
780
+
781
+ # @param label [String]
782
+ # @param name [String]
783
+ # @param value [String]
784
+ # @return [Wx::PG::DirProperty]
785
+ def initialize(label=Wx::PG::PG_LABEL, name=Wx::PG::PG_LABEL, value=('')) end
786
+
787
+ # Converts property value into a text representation.
788
+ #
789
+ # <div class="wxrb-remark">
790
+ # <b>Remark:</b>
791
+ # <p>Default implementation calls {Wx::PG::DirProperty#generate_composed_value}.
792
+ # </p>
793
+ # </div>
794
+ # @param value [Wx::Variant] Value to be converted.
795
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::Null} (default value), then displayed string is returned. If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable string value instead of displayable. If {Wx::PG::PGPropValFormatFlags::EditableValue} is set, returns string value that must be editable in textctrl. If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, returns text that is appropriate to display as a part of string property's composite text representation.
796
+ # @return [String]
797
+ def value_to_string(value, flags=PGPropValFormatFlags::Null) end
798
+
799
+ # Converts text into {Wx::Variant} value appropriate for this property.
800
+ #
801
+ # Returns true if resulting {Wx::Variant} value was different.
802
+ #
803
+ # <div class="wxrb-remark">
804
+ # <b>Remark:</b>
805
+ # <p>Default implementation converts semicolon delimited tokens into child values. Only works for properties with children.
806
+ # </p>
807
+ # </div>
808
+ #
809
+ # You might want to take into account that m_value is Null variant if property value is unspecified (which is usually only case if you explicitly enabled that sort behaviour).
810
+ # @param variant [Wx::Variant] On function entry this is the old value (should not be null {Wx::Variant} in normal cases). Translated value must be assigned back to it.
811
+ # @param text [String] Text to be translated into variant.
812
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable value instead of displayable one (they may be different). If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, text is interpreted as a part of composite property string value (as generated by {Wx::PG::DirProperty#value_to_string} called with this same flag).
813
+ # @return [Boolean]
814
+ def string_to_value(variant, text, flags=PGPropValFormatFlags::Null) end
815
+
816
+ # Returns pointer to the {Wx::Validator} that should be used with the editor of this property (nil for no validator).
817
+ #
818
+ # Setting validator explicitly via \#set_property_validator will override this.
819
+ # In most situations, code like this should work well:
820
+ #
821
+ # ```ruby
822
+ # class MyPropertyClass < Wx::PG::DirProperty
823
+ #
824
+ # class << self
825
+ # def validator
826
+ # @validator ||= MyValidator.new(...)
827
+ # end
828
+ # end
829
+ #
830
+ # # ...
831
+ #
832
+ # def do_get_validator
833
+ # MyPropertyClass.validator
834
+ # end
835
+ #
836
+ # # ...
837
+ #
838
+ # end
839
+ # ```
840
+ #
841
+ # <div class="wxrb-remark">
842
+ # <b>Remark:</b>
843
+ # <p>You can get common filename validator by returning {Wx::PG::FileProperty.get_class_validator}. {Wx::PG::DirProperty}, for example, uses it.
844
+ # </p>
845
+ # </div>
846
+ # @return [Wx::Validator]
847
+ def do_get_validator; end
848
+
849
+ #
850
+ # @return [Wx::Variant]
851
+ def value_; end
852
+ #
853
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
854
+ # @return [void]
855
+ def value_=(val); end
856
+
857
+
858
+ protected
859
+
860
+ # Shows editor dialog.
861
+ #
862
+ # Value to be edited should be read from value, and if dialog is not cancelled, it should be stored back and true should be returned.
863
+ #
864
+ # Returns true if editor dialog was not cancelled and value was updated.
865
+ # @param pg [Wx::PG::PropertyGrid] Property grid in which property is displayed.
866
+ # @param value [Wx::Variant] Value to be edited.
867
+ # @return [Boolean]
868
+ def display_editor_dialog(pg, value) end
869
+
870
+ end # DirProperty
871
+
872
+ # Like {Wx::PG::LongStringProperty}, but the button triggers file selector instead.
873
+ #
874
+ # <b>Supported special attributes:</b>
875
+ #
876
+ # - {Wx::PG::PG_DIALOG_TITLE}: Sets a specific title for the file dialog (since 3.1.3).
877
+ # - {Wx::PG::PG_FILE_DIALOG_STYLE}: Sets a specific {Wx::FileDialog} style for the file dialog (since 2.9.4).
878
+ # - {Wx::PG::PG_FILE_WILDCARD}: Sets wildcard (see {Wx::FileDialog} for format details), "All files..." is default.
879
+ # - {Wx::PG::PG_FILE_SHOW_FULL_PATH}: Default true. When false, only the file name is shown (i.e. drive and directory are hidden).
880
+ # - {Wx::PG::PG_FILE_SHOW_RELATIVE_PATH}: If set, then the filename is shown relative to the given path string.
881
+ # - {Wx::PG::PG_FILE_INITIAL_PATH}: Sets the initial path of where to look for files.
882
+ #
883
+ # @wxrb_require USE_PROPGRID
884
+ class FileProperty < EditorDialogProperty
885
+
886
+ # @param label [String]
887
+ # @param name [String]
888
+ # @param value [String]
889
+ # @return [Wx::PG::FileProperty]
890
+ def initialize(label=Wx::PG::PG_LABEL, name=Wx::PG::PG_LABEL, value=('')) end
891
+
892
+ # This virtual function is called after m_value has been set.
893
+ #
894
+ # <div class="wxrb-remark">
895
+ # <b>Remark:</b>
896
+ # <p>
897
+ #
898
+ # - If m_value was set to Null variant (i.e. unspecified value), {Wx::PG::FileProperty#on_set_value} will not be called.
899
+ # - m_value may be of any variant type. Typically properties internally support only one variant type, and as such {Wx::PG::FileProperty#on_set_value} provides a good opportunity to convert supported values into internal type.
900
+ # - Default implementation does nothing.
901
+ #
902
+ # </p>
903
+ # </div>
904
+ # @return [void]
905
+ def on_set_value; end
906
+
907
+ # Converts property value into a text representation.
908
+ #
909
+ # <div class="wxrb-remark">
910
+ # <b>Remark:</b>
911
+ # <p>Default implementation calls {Wx::PG::FileProperty#generate_composed_value}.
912
+ # </p>
913
+ # </div>
914
+ # @param value [Wx::Variant] Value to be converted.
915
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::Null} (default value), then displayed string is returned. If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable string value instead of displayable. If {Wx::PG::PGPropValFormatFlags::EditableValue} is set, returns string value that must be editable in textctrl. If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, returns text that is appropriate to display as a part of string property's composite text representation.
916
+ # @return [String]
917
+ def value_to_string(value, flags=PGPropValFormatFlags::Null) end
918
+
919
+ # Converts text into {Wx::Variant} value appropriate for this property.
920
+ #
921
+ # Returns true if resulting {Wx::Variant} value was different.
922
+ #
923
+ # <div class="wxrb-remark">
924
+ # <b>Remark:</b>
925
+ # <p>Default implementation converts semicolon delimited tokens into child values. Only works for properties with children.
926
+ # </p>
927
+ # </div>
928
+ #
929
+ # You might want to take into account that m_value is Null variant if property value is unspecified (which is usually only case if you explicitly enabled that sort behaviour).
930
+ # @param variant [Wx::Variant] On function entry this is the old value (should not be null {Wx::Variant} in normal cases). Translated value must be assigned back to it.
931
+ # @param text [String] Text to be translated into variant.
932
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable value instead of displayable one (they may be different). If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, text is interpreted as a part of composite property string value (as generated by {Wx::PG::FileProperty#value_to_string} called with this same flag).
933
+ # @return [Boolean]
934
+ def string_to_value(variant, text, flags=PGPropValFormatFlags::Null) end
935
+
936
+ # Reimplement this member function to add special handling for attributes of this property.
937
+ #
938
+ # Return false to have the attribute automatically stored in m_attributes. Default implementation simply does that and nothing else.
939
+ #
940
+ # <div class="wxrb-remark">
941
+ # <b>Remark:</b>
942
+ # <p>To actually set property attribute values from the application, use {Wx::PG::PGProperty#set_attribute} instead.
943
+ # </p>
944
+ # </div>
945
+ # @param name [String]
946
+ # @param value [Wx::Variant]
947
+ # @return [Boolean]
948
+ def do_set_attribute(name, value) end
949
+
950
+ # Returns pointer to the {Wx::Validator} that should be used with the editor of this property (nil for no validator).
951
+ #
952
+ # Setting validator explicitly via \#set_property_validator will override this.
953
+ # In most situations, code like this should work well:
954
+ #
955
+ # ```ruby
956
+ # class MyPropertyClass < Wx::PG::FileProperty
957
+ #
958
+ # class << self
959
+ # def validator
960
+ # @validator ||= MyValidator.new(...)
961
+ # end
962
+ # end
963
+ #
964
+ # # ...
965
+ #
966
+ # def do_get_validator
967
+ # MyPropertyClass.validator
968
+ # end
969
+ #
970
+ # # ...
971
+ #
972
+ # end
973
+ # ```
974
+ #
975
+ # <div class="wxrb-remark">
976
+ # <b>Remark:</b>
977
+ # <p>You can get common filename validator by returning {Wx::PG::FileProperty.get_class_validator}. {Wx::PG::DirProperty}, for example, uses it.
978
+ # </p>
979
+ # </div>
980
+ # @return [Wx::Validator]
981
+ def do_get_validator; end
982
+
983
+ # Returns filename to file represented by current value.
984
+ # @return [String]
985
+ def get_file_name; end
986
+ alias_method :file_name, :get_file_name
987
+
988
+ # @return [Wx::Validator]
989
+ def self.get_class_validator; end
990
+
991
+ #
992
+ #
993
+ #
994
+ # @return [String]
995
+ def m_wildcard; end
996
+ #
997
+ #
998
+ #
999
+ # @param val [String]
1000
+ # @return [void]
1001
+ def m_wildcard=(val); end
1002
+
1003
+ #
1004
+ #
1005
+ #
1006
+ # @return [String]
1007
+ def m_base_path; end
1008
+ #
1009
+ #
1010
+ #
1011
+ # @param val [String]
1012
+ # @return [void]
1013
+ def m_base_path=(val); end
1014
+
1015
+ #
1016
+ #
1017
+ #
1018
+ # @return [String]
1019
+ def m_initial_path; end
1020
+ #
1021
+ #
1022
+ #
1023
+ # @param val [String]
1024
+ # @return [void]
1025
+ def m_initial_path=(val); end
1026
+
1027
+ #
1028
+ #
1029
+ #
1030
+ # @return [Integer]
1031
+ def m_ind_filter; end
1032
+ #
1033
+ #
1034
+ #
1035
+ # @param val [Integer]
1036
+ # @return [void]
1037
+ def m_ind_filter=(val); end
1038
+
1039
+ #
1040
+ # @return [Wx::Variant]
1041
+ def value_; end
1042
+ #
1043
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
1044
+ # @return [void]
1045
+ def value_=(val); end
1046
+
1047
+
1048
+ protected
1049
+
1050
+ # Shows editor dialog.
1051
+ #
1052
+ # Value to be edited should be read from value, and if dialog is not cancelled, it should be stored back and true should be returned.
1053
+ #
1054
+ # Returns true if editor dialog was not cancelled and value was updated.
1055
+ # @param pg [Wx::PG::PropertyGrid] Property grid in which property is displayed.
1056
+ # @param value [Wx::Variant] Value to be edited.
1057
+ # @return [Boolean]
1058
+ def display_editor_dialog(pg, value) end
1059
+
1060
+ end # FileProperty
1061
+
1062
+ # Property representing image file(name).
1063
+ #
1064
+ # <b>Supported special attributes:</b>
1065
+ #
1066
+ # - {Wx::PG::PG_DIALOG_TITLE}: Sets a specific title for the file dialog (since 3.1.3).
1067
+ # - {Wx::PG::PG_FILE_DIALOG_STYLE}: Sets a specific {Wx::FileDialog} style for the file dialog.
1068
+ # - {Wx::PG::PG_FILE_WILDCARD}: Sets wildcard (see {Wx::FileDialog} for format details), "All
1069
+ # files..." is default.
1070
+ # - {Wx::PG::PG_FILE_SHOW_FULL_PATH}: Default true. When false, only the file name is shown (i.e. drive and directory are hidden).
1071
+ # - {Wx::PG::PG_FILE_SHOW_RELATIVE_PATH}: If set, then the filename is shown relative to the given path string.
1072
+ # - {Wx::PG::PG_FILE_INITIAL_PATH}: Sets the initial path of where to look for files.
1073
+ #
1074
+ # @wxrb_require USE_PROPGRID
1075
+ class ImageFileProperty < FileProperty
1076
+
1077
+ # @param label [String]
1078
+ # @param name [String]
1079
+ # @param value [String]
1080
+ # @return [Wx::PG::ImageFileProperty]
1081
+ def initialize(label=Wx::PG::PG_LABEL, name=Wx::PG::PG_LABEL, value=('')) end
1082
+
1083
+ # This virtual function is called after m_value has been set.
1084
+ #
1085
+ # <div class="wxrb-remark">
1086
+ # <b>Remark:</b>
1087
+ # <p>
1088
+ #
1089
+ # - If m_value was set to Null variant (i.e. unspecified value), {Wx::PG::ImageFileProperty#on_set_value} will not be called.
1090
+ # - m_value may be of any variant type. Typically properties internally support only one variant type, and as such {Wx::PG::ImageFileProperty#on_set_value} provides a good opportunity to convert supported values into internal type.
1091
+ # - Default implementation does nothing.
1092
+ #
1093
+ # </p>
1094
+ # </div>
1095
+ # @return [void]
1096
+ def on_set_value; end
1097
+
1098
+ # Returns size of the custom painted image in front of property.
1099
+ #
1100
+ # This method must be overridden to return non-default value if OnCustomPaint is to be called.
1101
+ #
1102
+ # <div class="wxrb-remark">
1103
+ # <b>Remark:</b>
1104
+ # <p>
1105
+ #
1106
+ # - Default behaviour is to return {size(0,0)}, which means no image.
1107
+ # - Default image width or height is indicated with dimension -1.
1108
+ # - You can also return {Wx::PG::PG_DEFAULT_IMAGE_SIZE} which equals {Wx::DEFAULT_SIZE}.
1109
+ #
1110
+ # </p>
1111
+ # </div>
1112
+ # @param item [Integer] Normally -1, but can be an index to the property's list of items.
1113
+ # @return [Wx::Size]
1114
+ def on_measure_image(item) end
1115
+
1116
+ # Override to paint an image in front of the property value text or drop-down list item (but only if {Wx::PG::PGProperty#on_measure_image} is overridden as well).
1117
+ #
1118
+ # If property's {Wx::PG::ImageFileProperty#on_measure_image} returns size that has height != 0 but less than row height ( < 0 has special meanings), {Wx::PG::PropertyGrid} calls this method to draw a custom image in a limited area in front of the editor control or value text/graphics, and if control has drop-down list, then the image is drawn there as well (even in the case {Wx::PG::ImageFileProperty#on_measure_image} returned higher height than row height).
1119
+ # NOTE: Following applies when {Wx::PG::ImageFileProperty#on_measure_image} returns a "flexible" height ( using <code>wxPG_FLEXIBLE_SIZE(W,H)</code> macro), which implies variable height items: If (rect.x+rect.width) is < 0, then this is a measure item call, which means that dc is invalid and only thing that should be done is to set paintdata.m_drawnHeight to the height of the image of item at index paintdata.m_choiceItem. This call may be done even as often as once every drop-down popup show.
1120
+ #
1121
+ # <div class="wxrb-remark">
1122
+ # <b>Remark:</b>
1123
+ # <p>
1124
+ #
1125
+ # - You can actually exceed rect width, but if you do so then paintdata.m_drawnWidth must be set to the full width drawn in pixels.
1126
+ # - Due to technical reasons, rect's height will be default even if custom height was reported during measure call.
1127
+ # - Brush is guaranteed to be default background colour. It has been already used to clear the background of area being painted. It can be modified.
1128
+ # - Pen is guaranteed to be 1-wide 'black' (or whatever is the proper colour) pen for drawing framing rectangle. It can be changed as well.
1129
+ #
1130
+ # </p>
1131
+ # </div>
1132
+ # @see Wx::PG::ImageFileProperty#value_to_string
1133
+ # @param dc [Wx::DC] {Wx::DC} to paint on.
1134
+ # @param rect [Wx::Rect] Box reserved for custom graphics. Includes surrounding rectangle, if any. If x+width is < 0, then this is a measure item call (see above).
1135
+ # @param paintdata [Wx::PG::PGPaintData] {Wx::PG::PGPaintData} structure with much useful data about painted item.
1136
+ # @return [void]
1137
+ def on_custom_paint(dc, rect, paintdata) end
1138
+
1139
+ #
1140
+ # @return [Wx::Variant]
1141
+ def value_; end
1142
+ #
1143
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
1144
+ # @return [void]
1145
+ def value_=(val); end
1146
+
1147
+ end # ImageFileProperty
1148
+
1149
+ # Property representing {Wx::Font}.
1150
+ #
1151
+ # <b>Supported special attributes:</b>
1152
+ #
1153
+ # - {Wx::PG::PG_DIALOG_TITLE}: Sets a specific title for the font dialog (since 3.1.3).
1154
+ #
1155
+ # @wxrb_require USE_PROPGRID
1156
+ class FontProperty < EditorDialogProperty
1157
+
1158
+ # @param label [String]
1159
+ # @param name [String]
1160
+ # @param value [Wx::Font,Wx::FontInfo]
1161
+ # @return [Wx::PG::FontProperty]
1162
+ def initialize(label=Wx::PG::PG_LABEL, name=Wx::PG::PG_LABEL, value=(Wx::Font.new())) end
1163
+
1164
+ # This virtual function is called after m_value has been set.
1165
+ #
1166
+ # <div class="wxrb-remark">
1167
+ # <b>Remark:</b>
1168
+ # <p>
1169
+ #
1170
+ # - If m_value was set to Null variant (i.e. unspecified value), {Wx::PG::FontProperty#on_set_value} will not be called.
1171
+ # - m_value may be of any variant type. Typically properties internally support only one variant type, and as such {Wx::PG::FontProperty#on_set_value} provides a good opportunity to convert supported values into internal type.
1172
+ # - Default implementation does nothing.
1173
+ #
1174
+ # </p>
1175
+ # </div>
1176
+ # @return [void]
1177
+ def on_set_value; end
1178
+
1179
+ # Converts property value into a text representation.
1180
+ #
1181
+ # <div class="wxrb-remark">
1182
+ # <b>Remark:</b>
1183
+ # <p>Default implementation calls {Wx::PG::FontProperty#generate_composed_value}.
1184
+ # </p>
1185
+ # </div>
1186
+ # @param value [Wx::Variant] Value to be converted.
1187
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::Null} (default value), then displayed string is returned. If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable string value instead of displayable. If {Wx::PG::PGPropValFormatFlags::EditableValue} is set, returns string value that must be editable in textctrl. If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, returns text that is appropriate to display as a part of string property's composite text representation.
1188
+ # @return [String]
1189
+ def value_to_string(value, flags=PGPropValFormatFlags::Null) end
1190
+
1191
+ # Called after value of a child property has been altered.
1192
+ #
1193
+ # Must return new value of the whole property (after any alterations warranted by child's new value).
1194
+ # Note that this function is usually called at the time that value of this property, or given child property, is still pending for change, and as such, result of {Wx::PG::FontProperty#get_value} or m_value should not be relied on.
1195
+ # Sample pseudo-code implementation:
1196
+ #
1197
+ # ```ruby
1198
+ # class WxFontDataProperty < Wx::PG::FontProperty
1199
+ #
1200
+ # def child_changed(thisValue, childIndex, childValue)
1201
+ # fontData = thisValue.object
1202
+ # fontData.initial_font = fontData.chosen_font
1203
+ #
1204
+ # case childIndex
1205
+ # when 6
1206
+ # col = childValue.colour
1207
+ # fontData.colour = col
1208
+ # else
1209
+ # # Transfer from subset to superset.
1210
+ # font = fontData.chosen_font
1211
+ # variant = Wx::Variant.new(font)
1212
+ # variant = super(variant, childIndex, childValue)
1213
+ # font = variant.font
1214
+ # fontData.chosen_font = font
1215
+ # end
1216
+ #
1217
+ # Wx::Variant.new(fontData)
1218
+ # end
1219
+ #
1220
+ # end
1221
+ # ```
1222
+ #
1223
+ # Modified value of the whole property.
1224
+ # @param thisValue [Wx::Variant] Value of this property. Changed value should be returned (in previous versions of {Wx::PG::PropertyGrid} it was only necessary to write value back to this argument).
1225
+ # @param childIndex [Integer] Index of child changed (you can use Item(childIndex) to get child property).
1226
+ # @param childValue [Wx::Variant] (Pending) value of the child property.
1227
+ # @return [Wx::Variant]
1228
+ def child_changed(thisValue, childIndex, childValue) end
1229
+
1230
+ # Refresh values of child properties.
1231
+ #
1232
+ # Automatically called after value is set.
1233
+ # @return [void]
1234
+ def refresh_children; end
1235
+
1236
+ #
1237
+ # @return [Wx::Variant]
1238
+ def value_; end
1239
+ #
1240
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
1241
+ # @return [void]
1242
+ def value_=(val); end
1243
+
1244
+
1245
+ protected
1246
+
1247
+ # Shows editor dialog.
1248
+ #
1249
+ # Value to be edited should be read from value, and if dialog is not cancelled, it should be stored back and true should be returned.
1250
+ #
1251
+ # Returns true if editor dialog was not cancelled and value was updated.
1252
+ # @param pg [Wx::PG::PropertyGrid] Property grid in which property is displayed.
1253
+ # @param value [Wx::Variant] Value to be edited.
1254
+ # @return [Boolean]
1255
+ def display_editor_dialog(pg, value) end
1256
+
1257
+ end # FontProperty
1258
+
1259
+ # Like {Wx::PG::StringProperty}, but has a button that triggers a small text editor dialog.
1260
+ #
1261
+ # <b>Supported special attributes:</b>
1262
+ #
1263
+ # - {Wx::PG::PG_DIALOG_TITLE}: Sets a specific title for the text editor dialog (since 3.1.3).
1264
+ #
1265
+ # @wxrb_require USE_PROPGRID
1266
+ class LongStringProperty < EditorDialogProperty
1267
+
1268
+ # @param label [String]
1269
+ # @param name [String]
1270
+ # @param value [String]
1271
+ # @return [Wx::PG::LongStringProperty]
1272
+ def initialize(label=Wx::PG::PG_LABEL, name=Wx::PG::PG_LABEL, value=('')) end
1273
+
1274
+ # Converts property value into a text representation.
1275
+ #
1276
+ # <div class="wxrb-remark">
1277
+ # <b>Remark:</b>
1278
+ # <p>Default implementation calls {Wx::PG::LongStringProperty#generate_composed_value}.
1279
+ # </p>
1280
+ # </div>
1281
+ # @param value [Wx::Variant] Value to be converted.
1282
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::Null} (default value), then displayed string is returned. If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable string value instead of displayable. If {Wx::PG::PGPropValFormatFlags::EditableValue} is set, returns string value that must be editable in textctrl. If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, returns text that is appropriate to display as a part of string property's composite text representation.
1283
+ # @return [String]
1284
+ def value_to_string(value, flags=PGPropValFormatFlags::Null) end
1285
+
1286
+ # Converts text into {Wx::Variant} value appropriate for this property.
1287
+ #
1288
+ # Returns true if resulting {Wx::Variant} value was different.
1289
+ #
1290
+ # <div class="wxrb-remark">
1291
+ # <b>Remark:</b>
1292
+ # <p>Default implementation converts semicolon delimited tokens into child values. Only works for properties with children.
1293
+ # </p>
1294
+ # </div>
1295
+ #
1296
+ # You might want to take into account that m_value is Null variant if property value is unspecified (which is usually only case if you explicitly enabled that sort behaviour).
1297
+ # @param variant [Wx::Variant] On function entry this is the old value (should not be null {Wx::Variant} in normal cases). Translated value must be assigned back to it.
1298
+ # @param text [String] Text to be translated into variant.
1299
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable value instead of displayable one (they may be different). If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, text is interpreted as a part of composite property string value (as generated by {Wx::PG::LongStringProperty#value_to_string} called with this same flag).
1300
+ # @return [Boolean]
1301
+ def string_to_value(variant, text, flags=PGPropValFormatFlags::Null) end
1302
+
1303
+ #
1304
+ # @return [Wx::Variant]
1305
+ def value_; end
1306
+ #
1307
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
1308
+ # @return [void]
1309
+ def value_=(val); end
1310
+
1311
+
1312
+ protected
1313
+
1314
+ # Shows editor dialog.
1315
+ #
1316
+ # Value to be edited should be read from value, and if dialog is not cancelled, it should be stored back and true should be returned.
1317
+ #
1318
+ # Returns true if editor dialog was not cancelled and value was updated.
1319
+ # @param pg [Wx::PG::PropertyGrid] Property grid in which property is displayed.
1320
+ # @param value [Wx::Variant] Value to be edited.
1321
+ # @return [Boolean]
1322
+ def display_editor_dialog(pg, value) end
1323
+
1324
+ end # LongStringProperty
1325
+
1326
+ # Property that manages a value resulting from {Wx::MultiChoiceDialog}.
1327
+ #
1328
+ # Value is array of strings. You can get value as array of choice values/indices by calling {Wx::PG::MultiChoiceProperty#get_value_as_array_int}.
1329
+ # <b>Supported special attributes:</b>
1330
+ #
1331
+ # - {Wx::PG::PG_ATTR_MULTICHOICE_USERSTRINGMODE}: If > 0, allow user to manually enter strings that are not in the list of choices. If this value is 1, user strings are preferably placed in front of valid choices. If value is 2, then those strings will placed behind valid choices.
1332
+ # - {Wx::PG::PG_DIALOG_TITLE}: Sets a specific title for the editor dialog (since 3.1.3).
1333
+ #
1334
+ # @wxrb_require USE_PROPGRID
1335
+ class MultiChoiceProperty < EditorDialogProperty
1336
+
1337
+ # @overload initialize(label, name, strings, value)
1338
+ # @param label [String]
1339
+ # @param name [String]
1340
+ # @param strings [Array<String>]
1341
+ # @param value [Array<String>]
1342
+ # @return [Wx::PG::MultiChoiceProperty]
1343
+ # @overload initialize(label, name, choices, value=(Wx::ArrayString.new()))
1344
+ # @param label [String]
1345
+ # @param name [String]
1346
+ # @param choices [Wx::PG::PGChoices]
1347
+ # @param value [Array<String>]
1348
+ # @return [Wx::PG::MultiChoiceProperty]
1349
+ # @overload initialize(label=Wx::PG::PG_LABEL, name=Wx::PG::PG_LABEL, value=(Wx::ArrayString.new()))
1350
+ # @param label [String]
1351
+ # @param name [String]
1352
+ # @param value [Array<String>]
1353
+ # @return [Wx::PG::MultiChoiceProperty]
1354
+ def initialize(*args) end
1355
+
1356
+ # This virtual function is called after m_value has been set.
1357
+ #
1358
+ # <div class="wxrb-remark">
1359
+ # <b>Remark:</b>
1360
+ # <p>
1361
+ #
1362
+ # - If m_value was set to Null variant (i.e. unspecified value), {Wx::PG::MultiChoiceProperty#on_set_value} will not be called.
1363
+ # - m_value may be of any variant type. Typically properties internally support only one variant type, and as such {Wx::PG::MultiChoiceProperty#on_set_value} provides a good opportunity to convert supported values into internal type.
1364
+ # - Default implementation does nothing.
1365
+ #
1366
+ # </p>
1367
+ # </div>
1368
+ # @return [void]
1369
+ def on_set_value; end
1370
+
1371
+ # Converts property value into a text representation.
1372
+ #
1373
+ # <div class="wxrb-remark">
1374
+ # <b>Remark:</b>
1375
+ # <p>Default implementation calls {Wx::PG::MultiChoiceProperty#generate_composed_value}.
1376
+ # </p>
1377
+ # </div>
1378
+ # @param value [Wx::Variant] Value to be converted.
1379
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::Null} (default value), then displayed string is returned. If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable string value instead of displayable. If {Wx::PG::PGPropValFormatFlags::EditableValue} is set, returns string value that must be editable in textctrl. If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, returns text that is appropriate to display as a part of string property's composite text representation.
1380
+ # @return [String]
1381
+ def value_to_string(value, flags=PGPropValFormatFlags::Null) end
1382
+
1383
+ # Converts text into {Wx::Variant} value appropriate for this property.
1384
+ #
1385
+ # Returns true if resulting {Wx::Variant} value was different.
1386
+ #
1387
+ # <div class="wxrb-remark">
1388
+ # <b>Remark:</b>
1389
+ # <p>Default implementation converts semicolon delimited tokens into child values. Only works for properties with children.
1390
+ # </p>
1391
+ # </div>
1392
+ #
1393
+ # You might want to take into account that m_value is Null variant if property value is unspecified (which is usually only case if you explicitly enabled that sort behaviour).
1394
+ # @param variant [Wx::Variant] On function entry this is the old value (should not be null {Wx::Variant} in normal cases). Translated value must be assigned back to it.
1395
+ # @param text [String] Text to be translated into variant.
1396
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable value instead of displayable one (they may be different). If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, text is interpreted as a part of composite property string value (as generated by {Wx::PG::MultiChoiceProperty#value_to_string} called with this same flag).
1397
+ # @return [Boolean]
1398
+ def string_to_value(variant, text, flags=PGPropValFormatFlags::Null) end
1399
+
1400
+ # @return [Array<Integer>]
1401
+ def get_value_as_array_int; end
1402
+ alias_method :value_as_array_int, :get_value_as_array_int
1403
+
1404
+ #
1405
+ #
1406
+ #
1407
+ # @return [String]
1408
+ def display_; end
1409
+ #
1410
+ #
1411
+ #
1412
+ # @param val [String]
1413
+ # @return [void]
1414
+ def display_=(val); end
1415
+
1416
+ #
1417
+ #
1418
+ #
1419
+ # @return [Integer]
1420
+ def user_string_mode_; end
1421
+ #
1422
+ #
1423
+ #
1424
+ # @param val [Integer]
1425
+ # @return [void]
1426
+ def user_string_mode_=(val); end
1427
+
1428
+ # @param value [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
1429
+ # @return [String]
1430
+ def generate_value_as_string(value) end
1431
+
1432
+ # @return [Array<Integer>]
1433
+ def get_value_as_indices; end
1434
+ alias_method :value_as_indices, :get_value_as_indices
1435
+
1436
+ #
1437
+ # @return [Wx::Variant]
1438
+ def value_; end
1439
+ #
1440
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
1441
+ # @return [void]
1442
+ def value_=(val); end
1443
+
1444
+
1445
+ protected
1446
+
1447
+ # Shows editor dialog.
1448
+ #
1449
+ # Value to be edited should be read from value, and if dialog is not cancelled, it should be stored back and true should be returned.
1450
+ #
1451
+ # Returns true if editor dialog was not cancelled and value was updated.
1452
+ # @param pg [Wx::PG::PropertyGrid] Property grid in which property is displayed.
1453
+ # @param value [Wx::Variant] Value to be edited.
1454
+ # @return [Boolean]
1455
+ def display_editor_dialog(pg, value) end
1456
+
1457
+ end # MultiChoiceProperty
1458
+
1459
+ # This is an abstract class which serves as a base class for numeric properties, like {Wx::PG::IntProperty}, {Wx::PG::UIntProperty}, {Wx::PG::FloatProperty}.
1460
+ #
1461
+ # <b>Supported special attributes:</b>
1462
+ #
1463
+ # - {Wx::PG::PG_ATTR_MIN}, {Wx::PG::PG_ATTR_MAX}: Specify acceptable value range.
1464
+ # - {Wx::PG::PG_ATTR_SPINCTRL_STEP}: How much number changes when SpinCtrl editor button is pressed (or up/down on keyboard).
1465
+ # - {Wx::PG::PG_ATTR_SPINCTRL_WRAP}: Specify if value modified with SpinCtrl editor wraps at Min/Max.
1466
+ # - {Wx::PG::PG_ATTR_SPINCTRL_MOTION}: Specify if value can also by changed with SpinCtrl editor by moving mouse when left mouse button is being pressed.
1467
+ #
1468
+ # @wxrb_require USE_PROPGRID
1469
+ class NumericProperty < PGProperty
1470
+
1471
+ # Reimplement this member function to add special handling for attributes of this property.
1472
+ #
1473
+ # Return false to have the attribute automatically stored in m_attributes. Default implementation simply does that and nothing else.
1474
+ #
1475
+ # <div class="wxrb-remark">
1476
+ # <b>Remark:</b>
1477
+ # <p>To actually set property attribute values from the application, use {Wx::PG::PGProperty#set_attribute} instead.
1478
+ # </p>
1479
+ # </div>
1480
+ # @param name [String]
1481
+ # @param value [Wx::Variant]
1482
+ # @return [Boolean]
1483
+ def do_set_attribute(name, value) end
1484
+
1485
+ # Returns what would be the new value of the property after adding SpinCtrl editor step to the current value.
1486
+ #
1487
+ # Current value range and wrapping (if enabled) are taken into account. This member has to be implemented in derived properties.
1488
+ #
1489
+ # Value which property would have after adding SpinCtrl editor step.
1490
+ #
1491
+ # <div class="wxrb-remark">
1492
+ # <b>Remark:</b>
1493
+ # <p>Current property value is not changed.
1494
+ # </p>
1495
+ # </div>
1496
+ # @param stepScale [Integer] SpinCtrl editor step is first multiplied by this factor and next added to the current value.
1497
+ # @return [Wx::Variant]
1498
+ def add_spin_step_value(stepScale) end
1499
+
1500
+ # Return true if value can be changed with SpinCtrl editor by moving the mouse.
1501
+ # @return [Boolean]
1502
+ def use_spin_motion; end
1503
+
1504
+ #
1505
+ #
1506
+ #
1507
+ # @return [Wx::Variant]
1508
+ def min_val_; end
1509
+ #
1510
+ #
1511
+ #
1512
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
1513
+ # @return [void]
1514
+ def min_val_=(val); end
1515
+
1516
+ #
1517
+ #
1518
+ #
1519
+ # @return [Wx::Variant]
1520
+ def max_val_; end
1521
+ #
1522
+ #
1523
+ #
1524
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
1525
+ # @return [void]
1526
+ def max_val_=(val); end
1527
+
1528
+ #
1529
+ #
1530
+ #
1531
+ # @return [Boolean]
1532
+ def spin_motion_; end
1533
+ #
1534
+ #
1535
+ #
1536
+ # @param val [Boolean]
1537
+ # @return [void]
1538
+ def spin_motion_=(val); end
1539
+
1540
+ #
1541
+ #
1542
+ #
1543
+ # @return [Wx::Variant]
1544
+ def spin_step_; end
1545
+ #
1546
+ #
1547
+ #
1548
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
1549
+ # @return [void]
1550
+ def spin_step_=(val); end
1551
+
1552
+ #
1553
+ #
1554
+ #
1555
+ # @return [Boolean]
1556
+ def spin_wrap_; end
1557
+ #
1558
+ #
1559
+ #
1560
+ # @param val [Boolean]
1561
+ # @return [void]
1562
+ def spin_wrap_=(val); end
1563
+
1564
+ #
1565
+ # @return [Wx::Variant]
1566
+ def value_; end
1567
+ #
1568
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
1569
+ # @return [void]
1570
+ def value_=(val); end
1571
+
1572
+
1573
+ protected
1574
+
1575
+ # Constructor is protected because {Wx::PG::NumericProperty} is only a base class for other numeric property classes.
1576
+ # @param label [String]
1577
+ # @param name [String]
1578
+ # @return [Wx::PG::NumericProperty]
1579
+ def initialize(label, name) end
1580
+
1581
+ end # NumericProperty
1582
+
1583
+ # Basic property with integer value.
1584
+ #
1585
+ # <b>Supported special attributes:</b>
1586
+ # - {Wx::PG::PG_ATTR_MIN}, {Wx::PG::PG_ATTR_MAX}, {Wx::PG::PG_ATTR_SPINCTRL_STEP}, {Wx::PG::PG_ATTR_SPINCTRL_WRAP}, {Wx::PG::PG_ATTR_SPINCTRL_MOTION}: like in {Wx::PG::NumericProperty}.
1587
+ #
1588
+ # @wxrb_require USE_PROPGRID
1589
+ class IntProperty < NumericProperty
1590
+
1591
+ # @overload initialize(label=Wx::PG::PG_LABEL, name=Wx::PG::PG_LABEL, value=0)
1592
+ # @param label [String]
1593
+ # @param name [String]
1594
+ # @param value [Integer]
1595
+ # @return [Wx::PG::IntProperty]
1596
+ # @overload initialize(label, name, value)
1597
+ # @param label [String]
1598
+ # @param name [String]
1599
+ # @param value [Integer]
1600
+ # @return [Wx::PG::IntProperty]
1601
+ def initialize(*args) end
1602
+
1603
+ # Converts property value into a text representation.
1604
+ #
1605
+ # <div class="wxrb-remark">
1606
+ # <b>Remark:</b>
1607
+ # <p>Default implementation calls {Wx::PG::IntProperty#generate_composed_value}.
1608
+ # </p>
1609
+ # </div>
1610
+ # @param value [Wx::Variant] Value to be converted.
1611
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::Null} (default value), then displayed string is returned. If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable string value instead of displayable. If {Wx::PG::PGPropValFormatFlags::EditableValue} is set, returns string value that must be editable in textctrl. If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, returns text that is appropriate to display as a part of string property's composite text representation.
1612
+ # @return [String]
1613
+ def value_to_string(value, flags=PGPropValFormatFlags::Null) end
1614
+
1615
+ # Converts text into {Wx::Variant} value appropriate for this property.
1616
+ #
1617
+ # Returns true if resulting {Wx::Variant} value was different.
1618
+ #
1619
+ # <div class="wxrb-remark">
1620
+ # <b>Remark:</b>
1621
+ # <p>Default implementation converts semicolon delimited tokens into child values. Only works for properties with children.
1622
+ # </p>
1623
+ # </div>
1624
+ #
1625
+ # You might want to take into account that m_value is Null variant if property value is unspecified (which is usually only case if you explicitly enabled that sort behaviour).
1626
+ # @param variant [Wx::Variant] On function entry this is the old value (should not be null {Wx::Variant} in normal cases). Translated value must be assigned back to it.
1627
+ # @param text [String] Text to be translated into variant.
1628
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable value instead of displayable one (they may be different). If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, text is interpreted as a part of composite property string value (as generated by {Wx::PG::IntProperty#value_to_string} called with this same flag).
1629
+ # @return [Boolean]
1630
+ def string_to_value(variant, text, flags=PGPropValFormatFlags::Null) end
1631
+
1632
+ # Implement this function in derived class to check the value.
1633
+ #
1634
+ # Return true if it is ok. Returning false prevents property change events from occurring.
1635
+ #
1636
+ # <div class="wxrb-remark">
1637
+ # <b>Remark:</b>
1638
+ # <p>
1639
+ #
1640
+ # - Default implementation always returns true.
1641
+ #
1642
+ # </p>
1643
+ # </div>
1644
+ # @param value [Wx::Variant]
1645
+ # @param validationInfo [Wx::PG::PGValidationInfo]
1646
+ # @return [Boolean]
1647
+ def validate_value(value, validationInfo) end
1648
+
1649
+ # Converts integer (possibly a choice selection) into {Wx::Variant} value appropriate for this property.
1650
+ #
1651
+ # Returns true if resulting {Wx::Variant} value was different.
1652
+ #
1653
+ # <div class="wxrb-remark">
1654
+ # <b>Remark:</b>
1655
+ # <p>
1656
+ #
1657
+ # - If property is not supposed to use choice or spinctrl or other editor with int-based value, it is not necessary to implement this method.
1658
+ # - Default implementation simply assign given int to m_value.
1659
+ # - If property uses choice control, and displays a dialog on some choice items, then it is preferred to display that dialog in IntToValue instead of OnEvent.
1660
+ # - You might want to take into account that m_value is Mull variant if property value is unspecified (which is usually only case if you explicitly enabled that sort behaviour).
1661
+ #
1662
+ # </p>
1663
+ # </div>
1664
+ # @param variant [Wx::Variant] On function entry this is the old value (should not be null {Wx::Variant} in normal cases). Translated value must be assigned back to it.
1665
+ # @param number [Integer] Integer to be translated into variant.
1666
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable value instead of displayable one.
1667
+ # @return [Boolean]
1668
+ def int_to_value(variant, number, flags=PGPropValFormatFlags::Null) end
1669
+
1670
+ # Returns pointer to the {Wx::Validator} that should be used with the editor of this property (nil for no validator).
1671
+ #
1672
+ # Setting validator explicitly via \#set_property_validator will override this.
1673
+ # In most situations, code like this should work well:
1674
+ #
1675
+ # ```ruby
1676
+ # class MyPropertyClass < Wx::PG::IntProperty
1677
+ #
1678
+ # class << self
1679
+ # def validator
1680
+ # @validator ||= MyValidator.new(...)
1681
+ # end
1682
+ # end
1683
+ #
1684
+ # # ...
1685
+ #
1686
+ # def do_get_validator
1687
+ # MyPropertyClass.validator
1688
+ # end
1689
+ #
1690
+ # # ...
1691
+ #
1692
+ # end
1693
+ # ```
1694
+ #
1695
+ # <div class="wxrb-remark">
1696
+ # <b>Remark:</b>
1697
+ # <p>You can get common filename validator by returning {Wx::PG::FileProperty.get_class_validator}. {Wx::PG::DirProperty}, for example, uses it.
1698
+ # </p>
1699
+ # </div>
1700
+ # @return [Wx::Validator]
1701
+ def do_get_validator; end
1702
+
1703
+ # Returns what would be the new value of the property after adding SpinCtrl editor step to the current value.
1704
+ #
1705
+ # Current value range and wrapping (if enabled) are taken into account. This member has to be implemented in derived properties.
1706
+ #
1707
+ # Value which property would have after adding SpinCtrl editor step.
1708
+ #
1709
+ # <div class="wxrb-remark">
1710
+ # <b>Remark:</b>
1711
+ # <p>Current property value is not changed.
1712
+ # </p>
1713
+ # </div>
1714
+ # @param stepScale [Integer] SpinCtrl editor step is first multiplied by this factor and next added to the current value.
1715
+ # @return [Wx::Variant]
1716
+ def add_spin_step_value(stepScale) end
1717
+
1718
+ # @return [Wx::Validator]
1719
+ def self.get_class_validator; end
1720
+
1721
+ #
1722
+ # @return [Wx::Variant]
1723
+ def value_; end
1724
+ #
1725
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
1726
+ # @return [void]
1727
+ def value_=(val); end
1728
+
1729
+ #
1730
+ # @return [Wx::Variant]
1731
+ def min_val_; end
1732
+ #
1733
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
1734
+ # @return [void]
1735
+ def min_val_=(val); end
1736
+
1737
+ #
1738
+ # @return [Wx::Variant]
1739
+ def max_val_; end
1740
+ #
1741
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
1742
+ # @return [void]
1743
+ def max_val_=(val); end
1744
+
1745
+ #
1746
+ # @return [Boolean]
1747
+ def spin_motion_; end
1748
+ #
1749
+ # @param val [Boolean]
1750
+ # @return [void]
1751
+ def spin_motion_=(val); end
1752
+
1753
+ #
1754
+ # @return [Wx::Variant]
1755
+ def spin_step_; end
1756
+ #
1757
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
1758
+ # @return [void]
1759
+ def spin_step_=(val); end
1760
+
1761
+ #
1762
+ # @return [Boolean]
1763
+ def spin_wrap_; end
1764
+ #
1765
+ # @param val [Boolean]
1766
+ # @return [void]
1767
+ def spin_wrap_=(val); end
1768
+
1769
+ end # IntProperty
1770
+
1771
+ # Basic property with double-precision floating point value.
1772
+ #
1773
+ # <b>Supported special attributes:</b>
1774
+ #
1775
+ # - {Wx::PG::PG_FLOAT_PRECISION}: Sets the (max) precision used when floating point value is rendered as text. The default -1 means infinite precision.
1776
+ # - {Wx::PG::PG_ATTR_MIN}, {Wx::PG::PG_ATTR_MAX}, {Wx::PG::PG_ATTR_SPINCTRL_STEP}, {Wx::PG::PG_ATTR_SPINCTRL_WRAP}, {Wx::PG::PG_ATTR_SPINCTRL_MOTION}: like in {Wx::PG::NumericProperty}.
1777
+ #
1778
+ # @wxrb_require USE_PROPGRID
1779
+ class FloatProperty < NumericProperty
1780
+
1781
+ # @param label [String]
1782
+ # @param name [String]
1783
+ # @param value [Float]
1784
+ # @return [Wx::PG::FloatProperty]
1785
+ def initialize(label=Wx::PG::PG_LABEL, name=Wx::PG::PG_LABEL, value=0.0) end
1786
+
1787
+ # Converts property value into a text representation.
1788
+ #
1789
+ # <div class="wxrb-remark">
1790
+ # <b>Remark:</b>
1791
+ # <p>Default implementation calls {Wx::PG::FloatProperty#generate_composed_value}.
1792
+ # </p>
1793
+ # </div>
1794
+ # @param value [Wx::Variant] Value to be converted.
1795
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::Null} (default value), then displayed string is returned. If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable string value instead of displayable. If {Wx::PG::PGPropValFormatFlags::EditableValue} is set, returns string value that must be editable in textctrl. If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, returns text that is appropriate to display as a part of string property's composite text representation.
1796
+ # @return [String]
1797
+ def value_to_string(value, flags=PGPropValFormatFlags::Null) end
1798
+
1799
+ # Converts text into {Wx::Variant} value appropriate for this property.
1800
+ #
1801
+ # Returns true if resulting {Wx::Variant} value was different.
1802
+ #
1803
+ # <div class="wxrb-remark">
1804
+ # <b>Remark:</b>
1805
+ # <p>Default implementation converts semicolon delimited tokens into child values. Only works for properties with children.
1806
+ # </p>
1807
+ # </div>
1808
+ #
1809
+ # You might want to take into account that m_value is Null variant if property value is unspecified (which is usually only case if you explicitly enabled that sort behaviour).
1810
+ # @param variant [Wx::Variant] On function entry this is the old value (should not be null {Wx::Variant} in normal cases). Translated value must be assigned back to it.
1811
+ # @param text [String] Text to be translated into variant.
1812
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable value instead of displayable one (they may be different). If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, text is interpreted as a part of composite property string value (as generated by {Wx::PG::FloatProperty#value_to_string} called with this same flag).
1813
+ # @return [Boolean]
1814
+ def string_to_value(variant, text, flags=PGPropValFormatFlags::Null) end
1815
+
1816
+ # Reimplement this member function to add special handling for attributes of this property.
1817
+ #
1818
+ # Return false to have the attribute automatically stored in m_attributes. Default implementation simply does that and nothing else.
1819
+ #
1820
+ # <div class="wxrb-remark">
1821
+ # <b>Remark:</b>
1822
+ # <p>To actually set property attribute values from the application, use {Wx::PG::PGProperty#set_attribute} instead.
1823
+ # </p>
1824
+ # </div>
1825
+ # @param name [String]
1826
+ # @param value [Wx::Variant]
1827
+ # @return [Boolean]
1828
+ def do_set_attribute(name, value) end
1829
+
1830
+ # Implement this function in derived class to check the value.
1831
+ #
1832
+ # Return true if it is ok. Returning false prevents property change events from occurring.
1833
+ #
1834
+ # <div class="wxrb-remark">
1835
+ # <b>Remark:</b>
1836
+ # <p>
1837
+ #
1838
+ # - Default implementation always returns true.
1839
+ #
1840
+ # </p>
1841
+ # </div>
1842
+ # @param value [Wx::Variant]
1843
+ # @param validationInfo [Wx::PG::PGValidationInfo]
1844
+ # @return [Boolean]
1845
+ def validate_value(value, validationInfo) end
1846
+
1847
+ # Returns pointer to the {Wx::Validator} that should be used with the editor of this property (nil for no validator).
1848
+ #
1849
+ # Setting validator explicitly via \#set_property_validator will override this.
1850
+ # In most situations, code like this should work well:
1851
+ #
1852
+ # ```ruby
1853
+ # class MyPropertyClass < Wx::PG::FloatProperty
1854
+ #
1855
+ # class << self
1856
+ # def validator
1857
+ # @validator ||= MyValidator.new(...)
1858
+ # end
1859
+ # end
1860
+ #
1861
+ # # ...
1862
+ #
1863
+ # def do_get_validator
1864
+ # MyPropertyClass.validator
1865
+ # end
1866
+ #
1867
+ # # ...
1868
+ #
1869
+ # end
1870
+ # ```
1871
+ #
1872
+ # <div class="wxrb-remark">
1873
+ # <b>Remark:</b>
1874
+ # <p>You can get common filename validator by returning {Wx::PG::FileProperty.get_class_validator}. {Wx::PG::DirProperty}, for example, uses it.
1875
+ # </p>
1876
+ # </div>
1877
+ # @return [Wx::Validator]
1878
+ def do_get_validator; end
1879
+
1880
+ # Returns what would be the new value of the property after adding SpinCtrl editor step to the current value.
1881
+ #
1882
+ # Current value range and wrapping (if enabled) are taken into account. This member has to be implemented in derived properties.
1883
+ #
1884
+ # Value which property would have after adding SpinCtrl editor step.
1885
+ #
1886
+ # <div class="wxrb-remark">
1887
+ # <b>Remark:</b>
1888
+ # <p>Current property value is not changed.
1889
+ # </p>
1890
+ # </div>
1891
+ # @param stepScale [Integer] SpinCtrl editor step is first multiplied by this factor and next added to the current value.
1892
+ # @return [Wx::Variant]
1893
+ def add_spin_step_value(stepScale) end
1894
+
1895
+ # @return [Wx::Validator]
1896
+ def self.get_class_validator; end
1897
+
1898
+ #
1899
+ #
1900
+ #
1901
+ # @return [Integer]
1902
+ def precision_; end
1903
+ #
1904
+ #
1905
+ #
1906
+ # @param val [Integer]
1907
+ # @return [void]
1908
+ def precision_=(val); end
1909
+
1910
+ #
1911
+ # @return [Wx::Variant]
1912
+ def value_; end
1913
+ #
1914
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
1915
+ # @return [void]
1916
+ def value_=(val); end
1917
+
1918
+ #
1919
+ # @return [Wx::Variant]
1920
+ def min_val_; end
1921
+ #
1922
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
1923
+ # @return [void]
1924
+ def min_val_=(val); end
1925
+
1926
+ #
1927
+ # @return [Wx::Variant]
1928
+ def max_val_; end
1929
+ #
1930
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
1931
+ # @return [void]
1932
+ def max_val_=(val); end
1933
+
1934
+ #
1935
+ # @return [Boolean]
1936
+ def spin_motion_; end
1937
+ #
1938
+ # @param val [Boolean]
1939
+ # @return [void]
1940
+ def spin_motion_=(val); end
1941
+
1942
+ #
1943
+ # @return [Wx::Variant]
1944
+ def spin_step_; end
1945
+ #
1946
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
1947
+ # @return [void]
1948
+ def spin_step_=(val); end
1949
+
1950
+ #
1951
+ # @return [Boolean]
1952
+ def spin_wrap_; end
1953
+ #
1954
+ # @param val [Boolean]
1955
+ # @return [void]
1956
+ def spin_wrap_=(val); end
1957
+
1958
+ end # FloatProperty
1959
+
1960
+ # Basic property with unsigned integer value.
1961
+ #
1962
+ # Seamlessly supports 64-bit integer ({Wx::ULongLong}) on overflow.
1963
+ # <b>Supported special attributes:</b>
1964
+ #
1965
+ # - {Wx::PG::PG_UINT_BASE}: Define base. Valid constants are {Wx::PG::PG_BASE_OCT}, {Wx::PG::PG_BASE_DEC}, {Wx::PG::PG_BASE_HEX} and {Wx::PG::PG_BASE_HEXL} (lowercase characters). Arbitrary bases are <b>not</b> supported.
1966
+ # - {Wx::PG::PG_UINT_PREFIX}: Possible values are {Wx::PG::PG_PREFIX_NONE}, {Wx::PG_PREFIX_0X}, and {Wx::PG::PG_PREFIX_DOLLAR_SIGN}. Only {Wx::PG::PG_PREFIX_NONE} works with Decimal and Octal numbers.
1967
+ # - {Wx::PG::PG_ATTR_MIN}, {Wx::PG::PG_ATTR_MAX}, {Wx::PG::PG_ATTR_SPINCTRL_STEP}, {Wx::PG::PG_ATTR_SPINCTRL_WRAP}, {Wx::PG::PG_ATTR_SPINCTRL_MOTION}: like in {Wx::PG::NumericProperty}.
1968
+ #
1969
+ # <div class="wxrb-remark">
1970
+ # <b>Remark:</b>
1971
+ # <p>
1972
+ #
1973
+ # - For example how to use seamless 64-bit integer support, see {Wx::PG::IntProperty} documentation (just use {Wx::ULongLong} instead of {Wx::LongLong}).
1974
+ #
1975
+ # </p>
1976
+ # </div>
1977
+ #
1978
+ # @wxrb_require USE_PROPGRID
1979
+ class UIntProperty < NumericProperty
1980
+
1981
+ # @overload initialize(label=Wx::PG::PG_LABEL, name=Wx::PG::PG_LABEL, value=0)
1982
+ # @param label [String]
1983
+ # @param name [String]
1984
+ # @param value [Integer]
1985
+ # @return [Wx::PG::UIntProperty]
1986
+ # @overload initialize(label, name, value)
1987
+ # @param label [String]
1988
+ # @param name [String]
1989
+ # @param value [Integer]
1990
+ # @return [Wx::PG::UIntProperty]
1991
+ def initialize(*args) end
1992
+
1993
+ # Converts property value into a text representation.
1994
+ #
1995
+ # <div class="wxrb-remark">
1996
+ # <b>Remark:</b>
1997
+ # <p>Default implementation calls {Wx::PG::UIntProperty#generate_composed_value}.
1998
+ # </p>
1999
+ # </div>
2000
+ # @param value [Wx::Variant] Value to be converted.
2001
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::Null} (default value), then displayed string is returned. If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable string value instead of displayable. If {Wx::PG::PGPropValFormatFlags::EditableValue} is set, returns string value that must be editable in textctrl. If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, returns text that is appropriate to display as a part of string property's composite text representation.
2002
+ # @return [String]
2003
+ def value_to_string(value, flags=PGPropValFormatFlags::Null) end
2004
+
2005
+ # Converts text into {Wx::Variant} value appropriate for this property.
2006
+ #
2007
+ # Returns true if resulting {Wx::Variant} value was different.
2008
+ #
2009
+ # <div class="wxrb-remark">
2010
+ # <b>Remark:</b>
2011
+ # <p>Default implementation converts semicolon delimited tokens into child values. Only works for properties with children.
2012
+ # </p>
2013
+ # </div>
2014
+ #
2015
+ # You might want to take into account that m_value is Null variant if property value is unspecified (which is usually only case if you explicitly enabled that sort behaviour).
2016
+ # @param variant [Wx::Variant] On function entry this is the old value (should not be null {Wx::Variant} in normal cases). Translated value must be assigned back to it.
2017
+ # @param text [String] Text to be translated into variant.
2018
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable value instead of displayable one (they may be different). If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, text is interpreted as a part of composite property string value (as generated by {Wx::PG::UIntProperty#value_to_string} called with this same flag).
2019
+ # @return [Boolean]
2020
+ def string_to_value(variant, text, flags=PGPropValFormatFlags::Null) end
2021
+
2022
+ # Reimplement this member function to add special handling for attributes of this property.
2023
+ #
2024
+ # Return false to have the attribute automatically stored in m_attributes. Default implementation simply does that and nothing else.
2025
+ #
2026
+ # <div class="wxrb-remark">
2027
+ # <b>Remark:</b>
2028
+ # <p>To actually set property attribute values from the application, use {Wx::PG::PGProperty#set_attribute} instead.
2029
+ # </p>
2030
+ # </div>
2031
+ # @param name [String]
2032
+ # @param value [Wx::Variant]
2033
+ # @return [Boolean]
2034
+ def do_set_attribute(name, value) end
2035
+
2036
+ # Implement this function in derived class to check the value.
2037
+ #
2038
+ # Return true if it is ok. Returning false prevents property change events from occurring.
2039
+ #
2040
+ # <div class="wxrb-remark">
2041
+ # <b>Remark:</b>
2042
+ # <p>
2043
+ #
2044
+ # - Default implementation always returns true.
2045
+ #
2046
+ # </p>
2047
+ # </div>
2048
+ # @param value [Wx::Variant]
2049
+ # @param validationInfo [Wx::PG::PGValidationInfo]
2050
+ # @return [Boolean]
2051
+ def validate_value(value, validationInfo) end
2052
+
2053
+ # Returns pointer to the {Wx::Validator} that should be used with the editor of this property (nil for no validator).
2054
+ #
2055
+ # Setting validator explicitly via \#set_property_validator will override this.
2056
+ # In most situations, code like this should work well:
2057
+ #
2058
+ # ```ruby
2059
+ # class MyPropertyClass < Wx::PG::UIntProperty
2060
+ #
2061
+ # class << self
2062
+ # def validator
2063
+ # @validator ||= MyValidator.new(...)
2064
+ # end
2065
+ # end
2066
+ #
2067
+ # # ...
2068
+ #
2069
+ # def do_get_validator
2070
+ # MyPropertyClass.validator
2071
+ # end
2072
+ #
2073
+ # # ...
2074
+ #
2075
+ # end
2076
+ # ```
2077
+ #
2078
+ # <div class="wxrb-remark">
2079
+ # <b>Remark:</b>
2080
+ # <p>You can get common filename validator by returning {Wx::PG::FileProperty.get_class_validator}. {Wx::PG::DirProperty}, for example, uses it.
2081
+ # </p>
2082
+ # </div>
2083
+ # @return [Wx::Validator]
2084
+ def do_get_validator; end
2085
+
2086
+ # Converts integer (possibly a choice selection) into {Wx::Variant} value appropriate for this property.
2087
+ #
2088
+ # Returns true if resulting {Wx::Variant} value was different.
2089
+ #
2090
+ # <div class="wxrb-remark">
2091
+ # <b>Remark:</b>
2092
+ # <p>
2093
+ #
2094
+ # - If property is not supposed to use choice or spinctrl or other editor with int-based value, it is not necessary to implement this method.
2095
+ # - Default implementation simply assign given int to m_value.
2096
+ # - If property uses choice control, and displays a dialog on some choice items, then it is preferred to display that dialog in IntToValue instead of OnEvent.
2097
+ # - You might want to take into account that m_value is Mull variant if property value is unspecified (which is usually only case if you explicitly enabled that sort behaviour).
2098
+ #
2099
+ # </p>
2100
+ # </div>
2101
+ # @param variant [Wx::Variant] On function entry this is the old value (should not be null {Wx::Variant} in normal cases). Translated value must be assigned back to it.
2102
+ # @param number [Integer] Integer to be translated into variant.
2103
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable value instead of displayable one.
2104
+ # @return [Boolean]
2105
+ def int_to_value(variant, number, flags=PGPropValFormatFlags::Null) end
2106
+
2107
+ # Returns what would be the new value of the property after adding SpinCtrl editor step to the current value.
2108
+ #
2109
+ # Current value range and wrapping (if enabled) are taken into account. This member has to be implemented in derived properties.
2110
+ #
2111
+ # Value which property would have after adding SpinCtrl editor step.
2112
+ #
2113
+ # <div class="wxrb-remark">
2114
+ # <b>Remark:</b>
2115
+ # <p>Current property value is not changed.
2116
+ # </p>
2117
+ # </div>
2118
+ # @param stepScale [Integer] SpinCtrl editor step is first multiplied by this factor and next added to the current value.
2119
+ # @return [Wx::Variant]
2120
+ def add_spin_step_value(stepScale) end
2121
+
2122
+ #
2123
+ #
2124
+ #
2125
+ # @return [Integer]
2126
+ def base_; end
2127
+ #
2128
+ #
2129
+ #
2130
+ # @param val [Integer]
2131
+ # @return [void]
2132
+ def base_=(val); end
2133
+
2134
+ #
2135
+ #
2136
+ #
2137
+ # @return [Integer]
2138
+ def real_base_; end
2139
+ #
2140
+ #
2141
+ #
2142
+ # @param val [Integer]
2143
+ # @return [void]
2144
+ def real_base_=(val); end
2145
+
2146
+ #
2147
+ #
2148
+ #
2149
+ # @return [Integer]
2150
+ def prefix_; end
2151
+ #
2152
+ #
2153
+ #
2154
+ # @param val [Integer]
2155
+ # @return [void]
2156
+ def prefix_=(val); end
2157
+
2158
+ #
2159
+ # @return [Wx::Variant]
2160
+ def value_; end
2161
+ #
2162
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
2163
+ # @return [void]
2164
+ def value_=(val); end
2165
+
2166
+ #
2167
+ # @return [Wx::Variant]
2168
+ def min_val_; end
2169
+ #
2170
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
2171
+ # @return [void]
2172
+ def min_val_=(val); end
2173
+
2174
+ #
2175
+ # @return [Wx::Variant]
2176
+ def max_val_; end
2177
+ #
2178
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
2179
+ # @return [void]
2180
+ def max_val_=(val); end
2181
+
2182
+ #
2183
+ # @return [Boolean]
2184
+ def spin_motion_; end
2185
+ #
2186
+ # @param val [Boolean]
2187
+ # @return [void]
2188
+ def spin_motion_=(val); end
2189
+
2190
+ #
2191
+ # @return [Wx::Variant]
2192
+ def spin_step_; end
2193
+ #
2194
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
2195
+ # @return [void]
2196
+ def spin_step_=(val); end
2197
+
2198
+ #
2199
+ # @return [Boolean]
2200
+ def spin_wrap_; end
2201
+ #
2202
+ # @param val [Boolean]
2203
+ # @return [void]
2204
+ def spin_wrap_=(val); end
2205
+
2206
+ end # UIntProperty
2207
+
2208
+ # You can derive custom properties with choices from this class.
2209
+ #
2210
+ # See {Wx::BaseEnumProperty} for remarks.
2211
+ #
2212
+ # <div class="wxrb-remark">
2213
+ # <b>Remark:</b>
2214
+ # <p>
2215
+ #
2216
+ # - Updating private index is important. You can do this either by calling {Wx::PG::EnumProperty#set_index} in IntToValue, and then letting Wx::BaseEnumProperty::OnSetValue be called (by not implementing it, or by calling super class function in it) -OR- you can just call SetIndex in OnSetValue.
2217
+ #
2218
+ # </p>
2219
+ # </div>
2220
+ #
2221
+ # @wxrb_require USE_PROPGRID
2222
+ class EnumProperty < PGProperty
2223
+
2224
+ # @overload initialize(label, name, choices, value=0)
2225
+ # @param label [String]
2226
+ # @param name [String]
2227
+ # @param choices [Wx::PG::PGChoices]
2228
+ # @param value [Integer]
2229
+ # @return [Wx::PG::EnumProperty]
2230
+ # @overload initialize(label, name, labels, values=(Wx::ArrayInt.new()), value=0)
2231
+ # @param label [String]
2232
+ # @param name [String]
2233
+ # @param labels [Array<String>]
2234
+ # @param values [Array<Integer>]
2235
+ # @param value [Integer]
2236
+ # @return [Wx::PG::EnumProperty]
2237
+ def initialize(*args) end
2238
+
2239
+ # @return [Integer]
2240
+ def get_item_count; end
2241
+ alias_method :item_count, :get_item_count
2242
+
2243
+ # This virtual function is called after m_value has been set.
2244
+ #
2245
+ # <div class="wxrb-remark">
2246
+ # <b>Remark:</b>
2247
+ # <p>
2248
+ #
2249
+ # - If m_value was set to Null variant (i.e. unspecified value), {Wx::PG::EnumProperty#on_set_value} will not be called.
2250
+ # - m_value may be of any variant type. Typically properties internally support only one variant type, and as such {Wx::PG::EnumProperty#on_set_value} provides a good opportunity to convert supported values into internal type.
2251
+ # - Default implementation does nothing.
2252
+ #
2253
+ # </p>
2254
+ # </div>
2255
+ # @return [void]
2256
+ def on_set_value; end
2257
+
2258
+ # Converts property value into a text representation.
2259
+ #
2260
+ # <div class="wxrb-remark">
2261
+ # <b>Remark:</b>
2262
+ # <p>Default implementation calls {Wx::PG::EnumProperty#generate_composed_value}.
2263
+ # </p>
2264
+ # </div>
2265
+ # @param value [Wx::Variant] Value to be converted.
2266
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::Null} (default value), then displayed string is returned. If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable string value instead of displayable. If {Wx::PG::PGPropValFormatFlags::EditableValue} is set, returns string value that must be editable in textctrl. If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, returns text that is appropriate to display as a part of string property's composite text representation.
2267
+ # @return [String]
2268
+ def value_to_string(value, flags=PGPropValFormatFlags::Null) end
2269
+
2270
+ # Converts text into {Wx::Variant} value appropriate for this property.
2271
+ #
2272
+ # Returns true if resulting {Wx::Variant} value was different.
2273
+ #
2274
+ # <div class="wxrb-remark">
2275
+ # <b>Remark:</b>
2276
+ # <p>Default implementation converts semicolon delimited tokens into child values. Only works for properties with children.
2277
+ # </p>
2278
+ # </div>
2279
+ #
2280
+ # You might want to take into account that m_value is Null variant if property value is unspecified (which is usually only case if you explicitly enabled that sort behaviour).
2281
+ # @param variant [Wx::Variant] On function entry this is the old value (should not be null {Wx::Variant} in normal cases). Translated value must be assigned back to it.
2282
+ # @param text [String] Text to be translated into variant.
2283
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable value instead of displayable one (they may be different). If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, text is interpreted as a part of composite property string value (as generated by {Wx::PG::EnumProperty#value_to_string} called with this same flag).
2284
+ # @return [Boolean]
2285
+ def string_to_value(variant, text, flags=PGPropValFormatFlags::Null) end
2286
+
2287
+ # Implement this function in derived class to check the value.
2288
+ #
2289
+ # Return true if it is ok. Returning false prevents property change events from occurring.
2290
+ #
2291
+ # <div class="wxrb-remark">
2292
+ # <b>Remark:</b>
2293
+ # <p>
2294
+ #
2295
+ # - Default implementation always returns true.
2296
+ #
2297
+ # </p>
2298
+ # </div>
2299
+ # @param value [Wx::Variant]
2300
+ # @param validationInfo [Wx::PG::PGValidationInfo]
2301
+ # @return [Boolean]
2302
+ def validate_value(value, validationInfo) end
2303
+
2304
+ # If {Wx::PG::PGPropValFormatFlags::FullValue} is not set in flags, then the value is interpreted as index to choices list.
2305
+ #
2306
+ # Otherwise, it is actual value.
2307
+ # @param variant [Wx::Variant]
2308
+ # @param number [Integer]
2309
+ # @param flags [Wx::PGPropValFormatFlags]
2310
+ # @return [Boolean]
2311
+ def int_to_value(variant, number, flags=PGPropValFormatFlags::Null) end
2312
+
2313
+ # @param value [Integer]
2314
+ # @return [Integer]
2315
+ def get_index_for_value(value) end
2316
+ alias_method :index_for_value, :get_index_for_value
2317
+
2318
+ # Returns which choice is currently selected.
2319
+ #
2320
+ # Only applies to properties which have choices.
2321
+ # Needs to reimplemented in derived class if property value does not map directly to a choice. Integer as index, bool, and string usually do.
2322
+ # @return [Integer]
2323
+ def get_choice_selection; end
2324
+ alias_method :choice_selection, :get_choice_selection
2325
+
2326
+ # @return [Integer]
2327
+ def get_index; end
2328
+ alias_method :index, :get_index
2329
+
2330
+ # @param index [Integer]
2331
+ # @return [void]
2332
+ def set_index(index) end
2333
+ alias_method :index=, :set_index
2334
+
2335
+ #
2336
+ # @return [Wx::Variant]
2337
+ def value_; end
2338
+ #
2339
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
2340
+ # @return [void]
2341
+ def value_=(val); end
2342
+
2343
+ end # EnumProperty
2344
+
2345
+ # Property representing {Wx::Cursor}.
2346
+ #
2347
+ #
2348
+ #
2349
+ # @wxrb_require USE_PROPGRID
2350
+ class CursorProperty < EnumProperty
2351
+
2352
+ # @param label [String]
2353
+ # @param name [String]
2354
+ # @param value [Integer]
2355
+ # @return [Wx::PG::CursorProperty]
2356
+ def initialize(label=Wx::PG::PG_LABEL, name=Wx::PG::PG_LABEL, value=0) end
2357
+
2358
+ # Converts property value into a text representation.
2359
+ #
2360
+ # <div class="wxrb-remark">
2361
+ # <b>Remark:</b>
2362
+ # <p>Default implementation calls {Wx::PG::CursorProperty#generate_composed_value}.
2363
+ # </p>
2364
+ # </div>
2365
+ # @param value [Wx::Variant] Value to be converted.
2366
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::Null} (default value), then displayed string is returned. If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable string value instead of displayable. If {Wx::PG::PGPropValFormatFlags::EditableValue} is set, returns string value that must be editable in textctrl. If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, returns text that is appropriate to display as a part of string property's composite text representation.
2367
+ # @return [String]
2368
+ def value_to_string(value, flags=PGPropValFormatFlags::Null) end
2369
+
2370
+ # Returns size of the custom painted image in front of property.
2371
+ #
2372
+ # This method must be overridden to return non-default value if OnCustomPaint is to be called.
2373
+ #
2374
+ # <div class="wxrb-remark">
2375
+ # <b>Remark:</b>
2376
+ # <p>
2377
+ #
2378
+ # - Default behaviour is to return {size(0,0)}, which means no image.
2379
+ # - Default image width or height is indicated with dimension -1.
2380
+ # - You can also return {Wx::PG::PG_DEFAULT_IMAGE_SIZE} which equals {Wx::DEFAULT_SIZE}.
2381
+ #
2382
+ # </p>
2383
+ # </div>
2384
+ # @param item [Integer] Normally -1, but can be an index to the property's list of items.
2385
+ # @return [Wx::Size]
2386
+ def on_measure_image(item) end
2387
+
2388
+ # Override to paint an image in front of the property value text or drop-down list item (but only if {Wx::PG::PGProperty#on_measure_image} is overridden as well).
2389
+ #
2390
+ # If property's {Wx::PG::CursorProperty#on_measure_image} returns size that has height != 0 but less than row height ( < 0 has special meanings), {Wx::PG::PropertyGrid} calls this method to draw a custom image in a limited area in front of the editor control or value text/graphics, and if control has drop-down list, then the image is drawn there as well (even in the case {Wx::PG::CursorProperty#on_measure_image} returned higher height than row height).
2391
+ # NOTE: Following applies when {Wx::PG::CursorProperty#on_measure_image} returns a "flexible" height ( using <code>wxPG_FLEXIBLE_SIZE(W,H)</code> macro), which implies variable height items: If (rect.x+rect.width) is < 0, then this is a measure item call, which means that dc is invalid and only thing that should be done is to set paintdata.m_drawnHeight to the height of the image of item at index paintdata.m_choiceItem. This call may be done even as often as once every drop-down popup show.
2392
+ #
2393
+ # <div class="wxrb-remark">
2394
+ # <b>Remark:</b>
2395
+ # <p>
2396
+ #
2397
+ # - You can actually exceed rect width, but if you do so then paintdata.m_drawnWidth must be set to the full width drawn in pixels.
2398
+ # - Due to technical reasons, rect's height will be default even if custom height was reported during measure call.
2399
+ # - Brush is guaranteed to be default background colour. It has been already used to clear the background of area being painted. It can be modified.
2400
+ # - Pen is guaranteed to be 1-wide 'black' (or whatever is the proper colour) pen for drawing framing rectangle. It can be changed as well.
2401
+ #
2402
+ # </p>
2403
+ # </div>
2404
+ # @see Wx::PG::CursorProperty#value_to_string
2405
+ # @param dc [Wx::DC] {Wx::DC} to paint on.
2406
+ # @param rect [Wx::Rect] Box reserved for custom graphics. Includes surrounding rectangle, if any. If x+width is < 0, then this is a measure item call (see above).
2407
+ # @param paintdata [Wx::PG::PGPaintData] {Wx::PG::PGPaintData} structure with much useful data about painted item.
2408
+ # @return [void]
2409
+ def on_custom_paint(dc, rect, paintdata) end
2410
+
2411
+ #
2412
+ # @return [Wx::Variant]
2413
+ def value_; end
2414
+ #
2415
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
2416
+ # @return [void]
2417
+ def value_=(val); end
2418
+
2419
+ end # CursorProperty
2420
+
2421
+ # {Wx::PG::EnumProperty} with {Wx::String} value and writable combo box editor.
2422
+ #
2423
+ # <div class="wxrb-remark">
2424
+ # <b>Remark:</b>
2425
+ # <p>Uses int value, similar to {Wx::PG::EnumProperty}, unless text entered by user is not in choices (in which case string value is used).
2426
+ # </p>
2427
+ # </div>
2428
+ #
2429
+ # @wxrb_require USE_PROPGRID
2430
+ class EditEnumProperty < EnumProperty
2431
+
2432
+ # @overload initialize(label=Wx::PG::PG_LABEL, name=Wx::PG::PG_LABEL, labels=(Wx::ArrayString.new()), values=(Wx::ArrayInt.new()), value=(''))
2433
+ # @param label [String]
2434
+ # @param name [String]
2435
+ # @param labels [Array<String>]
2436
+ # @param values [Array<Integer>]
2437
+ # @param value [String]
2438
+ # @return [Wx::PG::EditEnumProperty]
2439
+ # @overload initialize(label, name, choices, value=(''))
2440
+ # @param label [String]
2441
+ # @param name [String]
2442
+ # @param choices [Wx::PG::PGChoices]
2443
+ # @param value [String]
2444
+ # @return [Wx::PG::EditEnumProperty]
2445
+ def initialize(*args) end
2446
+
2447
+ # This virtual function is called after m_value has been set.
2448
+ #
2449
+ # <div class="wxrb-remark">
2450
+ # <b>Remark:</b>
2451
+ # <p>
2452
+ #
2453
+ # - If m_value was set to Null variant (i.e. unspecified value), {Wx::PG::EditEnumProperty#on_set_value} will not be called.
2454
+ # - m_value may be of any variant type. Typically properties internally support only one variant type, and as such {Wx::PG::EditEnumProperty#on_set_value} provides a good opportunity to convert supported values into internal type.
2455
+ # - Default implementation does nothing.
2456
+ #
2457
+ # </p>
2458
+ # </div>
2459
+ # @return [void]
2460
+ def on_set_value; end
2461
+
2462
+ # Converts text into {Wx::Variant} value appropriate for this property.
2463
+ #
2464
+ # Returns true if resulting {Wx::Variant} value was different.
2465
+ #
2466
+ # <div class="wxrb-remark">
2467
+ # <b>Remark:</b>
2468
+ # <p>Default implementation converts semicolon delimited tokens into child values. Only works for properties with children.
2469
+ # </p>
2470
+ # </div>
2471
+ #
2472
+ # You might want to take into account that m_value is Null variant if property value is unspecified (which is usually only case if you explicitly enabled that sort behaviour).
2473
+ # @param variant [Wx::Variant] On function entry this is the old value (should not be null {Wx::Variant} in normal cases). Translated value must be assigned back to it.
2474
+ # @param text [String] Text to be translated into variant.
2475
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable value instead of displayable one (they may be different). If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, text is interpreted as a part of composite property string value (as generated by {Wx::PG::EditEnumProperty#value_to_string} called with this same flag).
2476
+ # @return [Boolean]
2477
+ def string_to_value(variant, text, flags=PGPropValFormatFlags::Null) end
2478
+
2479
+ # Implement this function in derived class to check the value.
2480
+ #
2481
+ # Return true if it is ok. Returning false prevents property change events from occurring.
2482
+ #
2483
+ # <div class="wxrb-remark">
2484
+ # <b>Remark:</b>
2485
+ # <p>
2486
+ #
2487
+ # - Default implementation always returns true.
2488
+ #
2489
+ # </p>
2490
+ # </div>
2491
+ # @param value [Wx::Variant]
2492
+ # @param validationInfo [Wx::PG::PGValidationInfo]
2493
+ # @return [Boolean]
2494
+ def validate_value(value, validationInfo) end
2495
+
2496
+ #
2497
+ # @return [Wx::Variant]
2498
+ def value_; end
2499
+ #
2500
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
2501
+ # @return [void]
2502
+ def value_=(val); end
2503
+
2504
+ end # EditEnumProperty
2505
+
2506
+ # Has dropdown list of wxWidgets system colours.
2507
+ #
2508
+ # Value used is of {Wx::PG::ColourPropertyValue} type.
2509
+ # <b>Supported special attributes:</b> {Wx::PG::PG_COLOUR_ALLOW_CUSTOM}, {Wx::PG::PG_COLOUR_HAS_ALPHA}
2510
+ #
2511
+ # @wxrb_require USE_PROPGRID
2512
+ class SystemColourProperty < EnumProperty
2513
+
2514
+ # @param label [String]
2515
+ # @param name [String]
2516
+ # @param value [Wx::PG::ColourPropertyValue]
2517
+ # @return [Wx::PG::SystemColourProperty]
2518
+ def initialize(label=Wx::PG::PG_LABEL, name=Wx::PG::PG_LABEL, value=(Wx::ColourPropertyValue.new())) end
2519
+
2520
+ # This virtual function is called after m_value has been set.
2521
+ #
2522
+ # <div class="wxrb-remark">
2523
+ # <b>Remark:</b>
2524
+ # <p>
2525
+ #
2526
+ # - If m_value was set to Null variant (i.e. unspecified value), {Wx::PG::SystemColourProperty#on_set_value} will not be called.
2527
+ # - m_value may be of any variant type. Typically properties internally support only one variant type, and as such {Wx::PG::SystemColourProperty#on_set_value} provides a good opportunity to convert supported values into internal type.
2528
+ # - Default implementation does nothing.
2529
+ #
2530
+ # </p>
2531
+ # </div>
2532
+ # @return [void]
2533
+ def on_set_value; end
2534
+
2535
+ # If {Wx::PG::PGPropValFormatFlags::FullValue} is not set in flags, then the value is interpreted as index to choices list.
2536
+ #
2537
+ # Otherwise, it is actual value.
2538
+ # @param variant [Wx::Variant]
2539
+ # @param number [Integer]
2540
+ # @param flags [Wx::PGPropValFormatFlags]
2541
+ # @return [Boolean]
2542
+ def int_to_value(variant, number, flags=PGPropValFormatFlags::Null) end
2543
+
2544
+ # Override in derived class to customize how colours are printed as strings.
2545
+ # @param col [Wx::Colour,String,Symbol]
2546
+ # @param index [Integer]
2547
+ # @param flags [Wx::PGPropValFormatFlags]
2548
+ # @return [String]
2549
+ def colour_to_string(col, index, flags=PGPropValFormatFlags::Null) end
2550
+
2551
+ # Returns index of entry that triggers colour picker dialog (default is last).
2552
+ # @return [Integer]
2553
+ def get_custom_colour_index; end
2554
+ alias_method :custom_colour_index, :get_custom_colour_index
2555
+
2556
+ # Converts property value into a text representation.
2557
+ #
2558
+ # <div class="wxrb-remark">
2559
+ # <b>Remark:</b>
2560
+ # <p>Default implementation calls {Wx::PG::SystemColourProperty#generate_composed_value}.
2561
+ # </p>
2562
+ # </div>
2563
+ # @param value [Wx::Variant] Value to be converted.
2564
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::Null} (default value), then displayed string is returned. If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable string value instead of displayable. If {Wx::PG::PGPropValFormatFlags::EditableValue} is set, returns string value that must be editable in textctrl. If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, returns text that is appropriate to display as a part of string property's composite text representation.
2565
+ # @return [String]
2566
+ def value_to_string(value, flags=PGPropValFormatFlags::Null) end
2567
+
2568
+ # Converts text into {Wx::Variant} value appropriate for this property.
2569
+ #
2570
+ # Returns true if resulting {Wx::Variant} value was different.
2571
+ #
2572
+ # <div class="wxrb-remark">
2573
+ # <b>Remark:</b>
2574
+ # <p>Default implementation converts semicolon delimited tokens into child values. Only works for properties with children.
2575
+ # </p>
2576
+ # </div>
2577
+ #
2578
+ # You might want to take into account that m_value is Null variant if property value is unspecified (which is usually only case if you explicitly enabled that sort behaviour).
2579
+ # @param variant [Wx::Variant] On function entry this is the old value (should not be null {Wx::Variant} in normal cases). Translated value must be assigned back to it.
2580
+ # @param text [String] Text to be translated into variant.
2581
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable value instead of displayable one (they may be different). If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, text is interpreted as a part of composite property string value (as generated by {Wx::PG::SystemColourProperty#value_to_string} called with this same flag).
2582
+ # @return [Boolean]
2583
+ def string_to_value(variant, text, flags=PGPropValFormatFlags::Null) end
2584
+
2585
+ # Events received by editor widgets are processed here.
2586
+ #
2587
+ # Note that editor class usually processes most events. Some, such as button press events of TextCtrlAndButton class, can be handled here. Also, if custom handling for regular events is desired, then that can also be done (for example, {Wx::PG::SystemColourProperty} custom handles {Wx::EVT_CHOICE} to display colour picker dialog when 'custom' selection is made).
2588
+ # If the event causes value to be changed, {Wx::PG::SystemColourProperty#set_value_in_event} should be called to set the new value.
2589
+ # The parameter event is the associated {Wx::Event}.
2590
+ #
2591
+ # Should
2592
+ #
2593
+ # return true if any changes in value should be reported.
2594
+ #
2595
+ # <div class="wxrb-remark">
2596
+ # <b>Remark:</b>
2597
+ # <p>
2598
+ #
2599
+ # - If property uses choice control, and displays a dialog on some choice items, then it is preferred to display that dialog in IntToValue instead of OnEvent.
2600
+ #
2601
+ # </p>
2602
+ # </div>
2603
+ # @param propgrid [Wx::PG::PropertyGrid]
2604
+ # @param wnd_primary [Wx::Window]
2605
+ # @param event [Wx::Event]
2606
+ # @return [Boolean]
2607
+ def on_event(propgrid, wnd_primary, event) end
2608
+
2609
+ # Reimplement this member function to add special handling for attributes of this property.
2610
+ #
2611
+ # Return false to have the attribute automatically stored in m_attributes. Default implementation simply does that and nothing else.
2612
+ #
2613
+ # <div class="wxrb-remark">
2614
+ # <b>Remark:</b>
2615
+ # <p>To actually set property attribute values from the application, use {Wx::PG::PGProperty#set_attribute} instead.
2616
+ # </p>
2617
+ # </div>
2618
+ # @param name [String]
2619
+ # @param value [Wx::Variant]
2620
+ # @return [Boolean]
2621
+ def do_set_attribute(name, value) end
2622
+
2623
+ # Returns size of the custom painted image in front of property.
2624
+ #
2625
+ # This method must be overridden to return non-default value if OnCustomPaint is to be called.
2626
+ #
2627
+ # <div class="wxrb-remark">
2628
+ # <b>Remark:</b>
2629
+ # <p>
2630
+ #
2631
+ # - Default behaviour is to return {size(0,0)}, which means no image.
2632
+ # - Default image width or height is indicated with dimension -1.
2633
+ # - You can also return {Wx::PG::PG_DEFAULT_IMAGE_SIZE} which equals {Wx::DEFAULT_SIZE}.
2634
+ #
2635
+ # </p>
2636
+ # </div>
2637
+ # @param item [Integer] Normally -1, but can be an index to the property's list of items.
2638
+ # @return [Wx::Size]
2639
+ def on_measure_image(item) end
2640
+
2641
+ # Override to paint an image in front of the property value text or drop-down list item (but only if {Wx::PG::PGProperty#on_measure_image} is overridden as well).
2642
+ #
2643
+ # If property's {Wx::PG::SystemColourProperty#on_measure_image} returns size that has height != 0 but less than row height ( < 0 has special meanings), {Wx::PG::PropertyGrid} calls this method to draw a custom image in a limited area in front of the editor control or value text/graphics, and if control has drop-down list, then the image is drawn there as well (even in the case {Wx::PG::SystemColourProperty#on_measure_image} returned higher height than row height).
2644
+ # NOTE: Following applies when {Wx::PG::SystemColourProperty#on_measure_image} returns a "flexible" height ( using <code>wxPG_FLEXIBLE_SIZE(W,H)</code> macro), which implies variable height items: If (rect.x+rect.width) is < 0, then this is a measure item call, which means that dc is invalid and only thing that should be done is to set paintdata.m_drawnHeight to the height of the image of item at index paintdata.m_choiceItem. This call may be done even as often as once every drop-down popup show.
2645
+ #
2646
+ # <div class="wxrb-remark">
2647
+ # <b>Remark:</b>
2648
+ # <p>
2649
+ #
2650
+ # - You can actually exceed rect width, but if you do so then paintdata.m_drawnWidth must be set to the full width drawn in pixels.
2651
+ # - Due to technical reasons, rect's height will be default even if custom height was reported during measure call.
2652
+ # - Brush is guaranteed to be default background colour. It has been already used to clear the background of area being painted. It can be modified.
2653
+ # - Pen is guaranteed to be 1-wide 'black' (or whatever is the proper colour) pen for drawing framing rectangle. It can be changed as well.
2654
+ #
2655
+ # </p>
2656
+ # </div>
2657
+ # @see Wx::PG::SystemColourProperty#value_to_string
2658
+ # @param dc [Wx::DC] {Wx::DC} to paint on.
2659
+ # @param rect [Wx::Rect] Box reserved for custom graphics. Includes surrounding rectangle, if any. If x+width is < 0, then this is a measure item call (see above).
2660
+ # @param paintdata [Wx::PG::PGPaintData] {Wx::PG::PGPaintData} structure with much useful data about painted item.
2661
+ # @return [void]
2662
+ def on_custom_paint(dc, rect, paintdata) end
2663
+
2664
+ # Helper function to show the colour dialog.
2665
+ # @param variant [Wx::Variant]
2666
+ # @return [Boolean]
2667
+ def query_colour_from_user(variant) end
2668
+
2669
+ # Default is to use {Wx::SystemSettings.get_colour(index)}.
2670
+ #
2671
+ # Override to use custom colour tables etc.
2672
+ # @param index [Integer]
2673
+ # @return [Wx::Colour]
2674
+ def get_colour(index) end
2675
+ alias_method :colour, :get_colour
2676
+
2677
+ # @param pVariant [Wx::Variant]
2678
+ # @return [Wx::PG::ColourPropertyValue]
2679
+ def get_val(pVariant=nil) end
2680
+ alias_method :val, :get_val
2681
+
2682
+ # @param type [Integer]
2683
+ # @param colour [Wx::Colour,String,Symbol]
2684
+ # @return [void]
2685
+ def init(type, colour) end
2686
+
2687
+ # @param colour [Wx::Colour,String,Symbol]
2688
+ # @return [Integer]
2689
+ def col_to_ind(colour) end
2690
+
2691
+ #
2692
+ # @return [Wx::Variant]
2693
+ def value_; end
2694
+ #
2695
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
2696
+ # @return [void]
2697
+ def value_=(val); end
2698
+
2699
+
2700
+ protected
2701
+
2702
+ # @param v [Wx::PG::ColourPropertyValue]
2703
+ # @return [Wx::Variant]
2704
+ def do_translate_val(v) end
2705
+
2706
+ end # SystemColourProperty
2707
+
2708
+ # Allows to select a colour from the list or with colour dialog.
2709
+ #
2710
+ # Value used is of {Wx::PG::ColourPropertyValue} type.
2711
+ # <b>Supported special attributes:</b> {Wx::PG::PG_COLOUR_ALLOW_CUSTOM}, {Wx::PG::PG_COLOUR_HAS_ALPHA}
2712
+ #
2713
+ # @wxrb_require USE_PROPGRID
2714
+ class ColourProperty < SystemColourProperty
2715
+
2716
+ # @param label [String]
2717
+ # @param name [String]
2718
+ # @param value [Wx::Colour,String,Symbol]
2719
+ # @return [Wx::PG::ColourProperty]
2720
+ def initialize(label=Wx::PG::PG_LABEL, name=Wx::PG::PG_LABEL, value=Wx::WHITE) end
2721
+
2722
+ # Converts property value into a text representation.
2723
+ #
2724
+ # <div class="wxrb-remark">
2725
+ # <b>Remark:</b>
2726
+ # <p>Default implementation calls {Wx::PG::ColourProperty#generate_composed_value}.
2727
+ # </p>
2728
+ # </div>
2729
+ # @param value [Wx::Variant] Value to be converted.
2730
+ # @param flags [Wx::PGPropValFormatFlags] If {Wx::PG::PGPropValFormatFlags::Null} (default value), then displayed string is returned. If {Wx::PG::PGPropValFormatFlags::FullValue} is set, returns complete, storable string value instead of displayable. If {Wx::PG::PGPropValFormatFlags::EditableValue} is set, returns string value that must be editable in textctrl. If {Wx::PG::PGPropValFormatFlags::CompositeFragment} is set, returns text that is appropriate to display as a part of string property's composite text representation.
2731
+ # @return [String]
2732
+ def value_to_string(value, flags=PGPropValFormatFlags::Null) end
2733
+
2734
+ # Default is to use {Wx::SystemSettings.get_colour(index)}.
2735
+ #
2736
+ # Override to use custom colour tables etc.
2737
+ # @param index [Integer]
2738
+ # @return [Wx::Colour]
2739
+ def get_colour(index) end
2740
+ alias_method :colour, :get_colour
2741
+
2742
+ #
2743
+ # @return [Wx::Variant]
2744
+ def value_; end
2745
+ #
2746
+ # @param val [nil,String,Integer,Float,Time,Wx::Font,Wx::Colour,Wx::Variant,Array<WxVariant>,Array<String>,ObjectWx::PG::ColourPropertyValue]
2747
+ # @return [void]
2748
+ def value_=(val); end
2749
+
2750
+
2751
+ protected
2752
+
2753
+ # @param v [Wx::PG::ColourPropertyValue]
2754
+ # @return [Wx::Variant]
2755
+ def do_translate_val(v) end
2756
+
2757
+ end # ColourProperty
2758
+
2759
+ # Because text, background and other colours tend to differ between platforms, {Wx::PG::SystemColourProperty} must be able to select between system colour and, when necessary, to pick a custom one.
2760
+ #
2761
+ # {Wx::PG::SystemColourProperty} value makes this possible.
2762
+ #
2763
+ #
2764
+ # @note This class is <b>untracked</b> and should not be derived from nor instances extended!
2765
+ # @wxrb_require USE_PROPGRID
2766
+ class ColourPropertyValue < Object
2767
+
2768
+ # An integer value relating to the colour, and which exact meaning depends on the property with which it is used.
2769
+ # For {Wx::PG::SystemColourProperty}:
2770
+ # Any of {Wx::SYS_COLOUR_XXX}, or any web-colour ( use {Wx::PG_TO_WEB_COLOUR} macro - (currently unsupported) ), or {Wx::PG::PG_COLOUR_CUSTOM}.
2771
+ # For custom colour properties without values array specified:
2772
+ # index or {Wx::PG::PG_COLOUR_CUSTOM}
2773
+ # For custom colour properties <b>with</b> values array specified:
2774
+ # m_arrValues[index] or {Wx::PG::PG_COLOUR_CUSTOM}
2775
+ #
2776
+ # @return [Integer]
2777
+ def type_; end
2778
+ # An integer value relating to the colour, and which exact meaning depends on the property with which it is used.
2779
+ # For {Wx::PG::SystemColourProperty}:
2780
+ # Any of {Wx::SYS_COLOUR_XXX}, or any web-colour ( use {Wx::PG_TO_WEB_COLOUR} macro - (currently unsupported) ), or {Wx::PG::PG_COLOUR_CUSTOM}.
2781
+ # For custom colour properties without values array specified:
2782
+ # index or {Wx::PG::PG_COLOUR_CUSTOM}
2783
+ # For custom colour properties <b>with</b> values array specified:
2784
+ # m_arrValues[index] or {Wx::PG::PG_COLOUR_CUSTOM}
2785
+ #
2786
+ # @param val [Integer]
2787
+ # @return [void]
2788
+ def type_=(val); end
2789
+
2790
+ # Resulting colour.
2791
+ # Should be correct regardless of type.
2792
+ #
2793
+ # @return [Wx::Colour]
2794
+ def colour_; end
2795
+ # Resulting colour.
2796
+ # Should be correct regardless of type.
2797
+ #
2798
+ # @param val [Wx::Colour]
2799
+ # @return [void]
2800
+ def colour_=(val); end
2801
+
2802
+ # @overload initialize()
2803
+ # @return [Wx::PG::ColourPropertyValue]
2804
+ # @overload initialize(v)
2805
+ # @param v [Wx::PG::ColourPropertyValue]
2806
+ # @return [Wx::PG::ColourPropertyValue]
2807
+ # @overload initialize(colour)
2808
+ # @param colour [Wx::Colour,String,Symbol]
2809
+ # @return [Wx::PG::ColourPropertyValue]
2810
+ # @overload initialize(type)
2811
+ # @param type [Integer]
2812
+ # @return [Wx::PG::ColourPropertyValue]
2813
+ # @overload initialize(type, colour)
2814
+ # @param type [Integer]
2815
+ # @param colour [Wx::Colour,String,Symbol]
2816
+ # @return [Wx::PG::ColourPropertyValue]
2817
+ def initialize(*args) end
2818
+
2819
+ # @param type [Integer]
2820
+ # @param colour [Wx::Colour,String,Symbol]
2821
+ # @return [void]
2822
+ def init(type, colour) end
2823
+
2824
+ end # ColourPropertyValue
2825
+
2826
+
2827
+ end
2828
+
2829
+ end