gtk_paradise 0.9.120 → 0.12.25

Sign up to get free protection for your applications and to get access to all the features.
Files changed (516) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +15184 -5758
  3. data/bin/genity +26 -0
  4. data/bin/gtk_editor +7 -0
  5. data/doc/README.gen +15128 -5736
  6. data/doc/todo/TODO_FOR_THE_GTK_EDITOR.md +16 -0
  7. data/doc/todo/TODO_FOR_THE_GTK_PARADISE_PROJECT.md +300 -221
  8. data/doc/todo/recurring_todo_tasks.md +4 -3
  9. data/gtk_paradise.gemspec +28 -17
  10. data/lib/gtk_paradise/app/app.rb +82 -51
  11. data/lib/gtk_paradise/app/{app_module.rb → app_module/app_module.rb} +1149 -921
  12. data/lib/gtk_paradise/base_module/base_module.rb +6992 -33
  13. data/lib/gtk_paradise/base_module/class_methods/class_methods.rb +0 -0
  14. data/lib/gtk_paradise/base_module/colours.rb +52 -8
  15. data/lib/gtk_paradise/base_module/css.rb +327 -238
  16. data/lib/gtk_paradise/base_module/experimental.rb +119 -0
  17. data/lib/gtk_paradise/base_module/html_support.rb +40 -15
  18. data/lib/gtk_paradise/base_module/these_methods_work_for_gtk3_and_gtk4.rb +171 -0
  19. data/lib/gtk_paradise/base_module/widgets/widgets.rb +69 -0
  20. data/lib/gtk_paradise/base_module_and_app_module/base_module_and_app_module.rb +1 -1
  21. data/lib/gtk_paradise/colours/colour_palette/material_design.rb +239 -0
  22. data/lib/gtk_paradise/colours/gtk_colour_constants.rb +8 -2
  23. data/lib/gtk_paradise/colours/parse.rb +8 -1
  24. data/lib/gtk_paradise/commandline/commandline.rb +20 -19
  25. data/lib/gtk_paradise/constants/constants.rb +237 -7
  26. data/lib/gtk_paradise/css_files/borders.css +81 -0
  27. data/lib/gtk_paradise/css_files/colours.css +332 -328
  28. data/lib/gtk_paradise/css_files/css_accordion.css +6 -2
  29. data/lib/gtk_paradise/css_files/hover_effects.css +588 -0
  30. data/lib/gtk_paradise/css_files/project.css +152 -188
  31. data/lib/gtk_paradise/drawing/README.md +3 -0
  32. data/lib/gtk_paradise/drawing/drawing.rb +68 -0
  33. data/lib/gtk_paradise/drawing/event.rb +73 -0
  34. data/lib/gtk_paradise/drawing/star.rb +96 -0
  35. data/lib/gtk_paradise/drawing/tool.rb +268 -0
  36. data/lib/gtk_paradise/drawing/turtle.rb +138 -0
  37. data/lib/gtk_paradise/emojis/emojis.rb +14 -13
  38. data/lib/gtk_paradise/examples/advanced/001_5x5_grid_example.rb +35 -50
  39. data/lib/gtk_paradise/examples/advanced/002_advanced_drag_and_drop_example.rb +21 -13
  40. data/lib/gtk_paradise/examples/advanced/003_html_like_support.rb +4 -25
  41. data/lib/gtk_paradise/examples/advanced/004_on_hover_example_on_gtk_entry.rb +4 -4
  42. data/lib/gtk_paradise/examples/advanced/005_csv_example.rb +6 -2
  43. data/lib/gtk_paradise/examples/advanced/007_label_responding_to_events_example.rb +1 -10
  44. data/lib/gtk_paradise/examples/advanced/008_options_example.rb +6 -3
  45. data/lib/gtk_paradise/examples/advanced/009_key_events.rb +1 -1
  46. data/lib/gtk_paradise/examples/advanced/010_extensive_text_view_example.rb +18 -17
  47. data/lib/gtk_paradise/examples/advanced/011_moving_blocks_example.rb +3 -3
  48. data/lib/gtk_paradise/examples/advanced/012_cell_data_sorting_example.rb +3 -4
  49. data/lib/gtk_paradise/examples/advanced/013_advanced_css_example.rb +86 -49
  50. data/lib/gtk_paradise/examples/advanced/014_popup_example.rb +9 -9
  51. data/lib/gtk_paradise/examples/advanced/015_advanced_button_example.rb +7 -19
  52. data/lib/gtk_paradise/examples/advanced/017_lean_CSS_example.rb +10 -13
  53. data/lib/gtk_paradise/examples/advanced/018_coloured_text_example.rb +7 -13
  54. data/lib/gtk_paradise/examples/advanced/019_gtk_entry_showing_the_cursor_position.rb +1 -1
  55. data/lib/gtk_paradise/examples/advanced/020_scale_this_image.rb +2 -14
  56. data/lib/gtk_paradise/examples/advanced/021_scroll_events_on_gtk_entry.rb +4 -0
  57. data/lib/gtk_paradise/examples/advanced/022_autogenerated_CSS_rounded_borders.rb +142 -0
  58. data/lib/gtk_paradise/examples/advanced/023_append_image_to_buffer.rb +145 -0
  59. data/lib/gtk_paradise/examples/advanced/024_notebook_with_tab_example.rb +204 -0
  60. data/lib/gtk_paradise/examples/advanced/025_showing_a_gold_caret_on_black_background.rb +144 -0
  61. data/lib/gtk_paradise/examples/advanced/026_status_bar_example.rb +153 -0
  62. data/lib/gtk_paradise/examples/advanced/027_customized_frame_example.rb +161 -0
  63. data/lib/gtk_paradise/examples/advanced/028_widgets_described_in_a_yaml_file.rb +240 -0
  64. data/lib/gtk_paradise/examples/advanced/029_entry_completion_example.rb +141 -0
  65. data/lib/gtk_paradise/examples/cairo/basic_cairo_shapes.rb +1 -1
  66. data/lib/gtk_paradise/examples/cairo/cairo_transparent_rectangles.rb +9 -5
  67. data/lib/gtk_paradise/examples/cairo/cairo_write_via_custom_font.rb +81 -0
  68. data/lib/gtk_paradise/examples/cairo/donut_shape.rb +19 -6
  69. data/lib/gtk_paradise/examples/cairo/ping_pong_game.rb +2 -3
  70. data/lib/gtk_paradise/examples/controller/README.md +4 -0
  71. data/lib/gtk_paradise/examples/controller/controller.rb +2 -0
  72. data/lib/gtk_paradise/examples/css/001_border_examples.rb +30 -13
  73. data/lib/gtk_paradise/examples/css/002_import_CSS_file.rb +10 -5
  74. data/lib/gtk_paradise/examples/drawing/001_example.rb +61 -0
  75. data/lib/gtk_paradise/examples/drawing/002_example.rb +51 -0
  76. data/lib/gtk_paradise/examples/drawing/003_example.rb +38 -0
  77. data/lib/gtk_paradise/examples/drawing/004_example.rb +36 -0
  78. data/lib/gtk_paradise/examples/drawing/005_example.rb +92 -0
  79. data/lib/gtk_paradise/examples/drawing/006_example.rb +58 -0
  80. data/lib/gtk_paradise/examples/drawing/007_example.rb +22 -0
  81. data/lib/gtk_paradise/examples/drawing/008_example.rb +43 -0
  82. data/lib/gtk_paradise/examples/drawing/009_example.rb +43 -0
  83. data/lib/gtk_paradise/examples/drawing/010_example.rb +25 -0
  84. data/lib/gtk_paradise/examples/drawing/011_example.rb +72 -0
  85. data/lib/gtk_paradise/examples/drawing/012_example.rb +59 -0
  86. data/lib/gtk_paradise/examples/drawing/README.md +3 -0
  87. data/lib/gtk_paradise/examples/drawing/moving_turtle_example.rb +43 -0
  88. data/lib/gtk_paradise/examples/gdk/001_gdk_screen_properties.rb +58 -0
  89. data/lib/gtk_paradise/examples/gdk_pixbuf/save_image_example.rb +1 -1
  90. data/lib/gtk_paradise/examples/gir_ffi/001_hello_world.rb +29 -0
  91. data/lib/gtk_paradise/examples/gir_ffi/002_upgraded_hello_world.rb +40 -0
  92. data/lib/gtk_paradise/examples/gir_ffi/003_gtk_application_example.rb +30 -0
  93. data/lib/gtk_paradise/examples/gir_ffi/004_treeview_example.rb +64 -0
  94. data/lib/gtk_paradise/examples/gir_ffi/005_complex_example.rb +104 -0
  95. data/lib/gtk_paradise/examples/gir_ffi/README.md +5 -0
  96. data/lib/gtk_paradise/examples/gir_ffi/advanced/001_advanced_treeview_example.rb +75 -0
  97. data/lib/gtk_paradise/examples/gir_ffi/advanced/README.md +2 -0
  98. data/lib/gtk_paradise/examples/glib/parse_glib_settings.rb +1 -1
  99. data/lib/gtk_paradise/examples/gtk2/008_list_store_example.rb +1 -1
  100. data/lib/gtk_paradise/examples/gtk3/{061_gtk_entry.rb → 001_gtk_entry.rb} +11 -6
  101. data/lib/gtk_paradise/examples/gtk3/{009_scrolled_window_example.rb → 002_scrolled_window_example.rb} +6 -4
  102. data/lib/gtk_paradise/examples/gtk3/{062_toggle_button_example.rb → 003_toggle_button_example.rb} +3 -2
  103. data/lib/gtk_paradise/examples/gtk3/{081_simple_dialog_example.rb → 004_simple_dialog_example.rb} +19 -12
  104. data/lib/gtk_paradise/examples/gtk3/005_spinner_example.rb +30 -10
  105. data/lib/gtk_paradise/examples/gtk3/006_text_view_example.rb +78 -0
  106. data/lib/gtk_paradise/examples/gtk3/{079_two_windows_example.rb → 007_two_windows_example.rb} +3 -1
  107. data/lib/gtk_paradise/examples/gtk3/008_search_bar_example.rb +91 -0
  108. data/lib/gtk_paradise/examples/gtk3/{002_simple_window.rb → 009_simple_window.rb} +14 -6
  109. data/lib/gtk_paradise/examples/gtk3/{025_switch_example.rb → 010_switch_example.rb} +6 -7
  110. data/lib/gtk_paradise/examples/gtk3/011_colour_chooser_example.rb +71 -0
  111. data/lib/gtk_paradise/examples/gtk3/012_show_the_xid_example.rb +18 -0
  112. data/lib/gtk_paradise/examples/gtk3/013_grab_pointer_forcefully.rb +31 -0
  113. data/lib/gtk_paradise/examples/gtk3/{083_bottom_left_placement.rb → 015_bottom_left_placement.rb} +3 -1
  114. data/lib/gtk_paradise/examples/gtk3/{082_scrolling_example.rb → 016_scrolling_example.rb} +2 -2
  115. data/lib/gtk_paradise/examples/gtk3/{080_extensive_markup_example.rb → 017_extensive_markup_example.rb} +8 -7
  116. data/lib/gtk_paradise/examples/gtk3/{078_message_dialog_example.rb → 018_message_dialog_example.rb} +3 -5
  117. data/lib/gtk_paradise/examples/gtk3/{075_tiny_button_via_css.rb → 021_tiny_button_via_css.rb} +1 -0
  118. data/lib/gtk_paradise/examples/gtk3/{001_font_related_information.rb → 022_font_related_information.rb} +1 -1
  119. data/lib/gtk_paradise/examples/gtk3/023_sorted_tree.rb +166 -0
  120. data/lib/gtk_paradise/examples/gtk3/{004_small_paned_example.rb → 024_small_paned_example.rb} +4 -3
  121. data/lib/gtk_paradise/examples/gtk3/{007_progress_bar_example.rb → 026_progress_bar_example.rb} +1 -2
  122. data/lib/gtk_paradise/examples/gtk3/{008_menubar_example.rb → 027_menubar_example.rb} +1 -1
  123. data/lib/gtk_paradise/examples/gtk3/{010_paned_widget_example.rb → 028_paned_widget_example.rb} +31 -1
  124. data/lib/gtk_paradise/examples/gtk3/{011_sockets.rb → 029_sockets.rb} +1 -0
  125. data/lib/gtk_paradise/examples/gtk3/{012_notebook_example.rb → 030_notebook_example.rb} +12 -4
  126. data/lib/gtk_paradise/examples/gtk3/{013_icon_theme_example.rb → 031_icon_theme_example.rb} +6 -0
  127. data/lib/gtk_paradise/examples/gtk3/{014_switcher_window.rb → 032_switcher_window.rb} +16 -10
  128. data/lib/gtk_paradise/examples/gtk3/{016_hello_world_in_gtk3_and_bold_font.rb → 034_hello_world_in_gtk3_and_bold_font.rb} +1 -1
  129. data/lib/gtk_paradise/examples/gtk3/{017_grid_example.rb → 035_grid_example.rb} +5 -1
  130. data/lib/gtk_paradise/examples/gtk3/{018_buttons_showcasing_the_relief.rb → 036_buttons_showcasing_the_relief.rb} +1 -0
  131. data/lib/gtk_paradise/examples/gtk3/{019_text_buffer_example.rb → 037_text_buffer_example.rb} +12 -10
  132. data/lib/gtk_paradise/examples/gtk3/{020_radio_button_window.rb → 038_radio_button_window.rb} +9 -9
  133. data/lib/gtk_paradise/examples/gtk3/{022_popup_example.rb → 040_popup_example.rb} +2 -2
  134. data/lib/gtk_paradise/examples/gtk3/{023_horizontal_and_vertical_scale.rb → 041_horizontal_and_vertical_scale.rb} +1 -1
  135. data/lib/gtk_paradise/examples/gtk3/{026_hover_button_example_via_css.rb → 043_hover_button_example_via_css.rb} +3 -1
  136. data/lib/gtk_paradise/examples/gtk3/{027_spin_button_example.rb → 044_spin_button_example.rb} +4 -3
  137. data/lib/gtk_paradise/examples/gtk3/{028_radio_menu_item_example.rb → 045_radio_menu_item_example.rb} +4 -1
  138. data/lib/gtk_paradise/examples/gtk3/{029_gtk_dialog_sample.rb → 046_gtk_dialog_sample.rb} +4 -1
  139. data/lib/gtk_paradise/examples/gtk3/{030_draw_rectangles.rb → 047_draw_rectangles.rb} +1 -1
  140. data/lib/gtk_paradise/examples/gtk3/{031_colour_choose_button.rb → 048_colour_choose_button.rb} +17 -3
  141. data/lib/gtk_paradise/examples/gtk3/{032_drag_and_drop_example.rb → 049_drag_and_drop_example.rb} +13 -5
  142. data/lib/gtk_paradise/examples/gtk3/{033_cell_renderer_pixbuf_example.rb → 050_cell_renderer_pixbuf_example.rb} +17 -6
  143. data/lib/gtk_paradise/examples/gtk3/051_combo_box_example.rb +84 -0
  144. data/lib/gtk_paradise/examples/gtk3/{035_notebook_css_example.rb → 052_notebook_css_example.rb} +3 -2
  145. data/lib/gtk_paradise/examples/gtk3/{037_css_example_of_a_button_changing_the_background_colour_on_click_event.rb → 053_css_example_of_a_button_changing_the_background_colour_on_click_event.rb} +14 -4
  146. data/lib/gtk_paradise/examples/gtk3/{036_revealer_example.rb → 053_revealer_example.rb} +10 -6
  147. data/lib/gtk_paradise/examples/gtk3/{038_ten_labels_in_a_vertical_box_example.rb → 054_ten_labels_in_a_vertical_box_example.rb} +1 -1
  148. data/lib/gtk_paradise/examples/gtk3/{039_threads_example.rb → 055_threads_example.rb} +1 -1
  149. data/lib/gtk_paradise/examples/gtk3/{042_colourized_button_example.rb → 058_colourized_button_example.rb} +1 -2
  150. data/lib/gtk_paradise/examples/gtk3/{043_form_example.rb → 059_form_example.rb} +1 -3
  151. data/lib/gtk_paradise/examples/gtk3/{044_check_button.rb → 060_check_button.rb} +4 -2
  152. data/lib/gtk_paradise/examples/gtk3/{046_event_box_example.rb → 062_event_box_example.rb} +13 -2
  153. data/lib/gtk_paradise/examples/gtk3/{047_examples_with_css.rb → 063_examples_with_css.rb} +91 -3
  154. data/lib/gtk_paradise/examples/gtk3/{048_accel_group_example.rb → 064_accel_group_example.rb} +1 -0
  155. data/lib/gtk_paradise/examples/gtk3/{049_change_the_application_theme.rb → 065_change_the_application_theme.rb} +4 -2
  156. data/lib/gtk_paradise/examples/gtk3/{050_header_bar_example.rb → 066_header_bar_example.rb} +3 -0
  157. data/lib/gtk_paradise/examples/gtk3/{051_gtk_label_example.rb → 067_gtk_label_example.rb} +3 -2
  158. data/lib/gtk_paradise/examples/gtk3/{052_popover_example.rb → 068_popover_example.rb} +2 -2
  159. data/lib/gtk_paradise/examples/gtk3/{053_entry_completion.rb → 069_entry_completion.rb} +2 -0
  160. data/lib/gtk_paradise/examples/gtk3/{055_button_demo.rb → 071_button_demo.rb} +6 -5
  161. data/lib/gtk_paradise/examples/gtk3/{056_text_iterator_example.rb → 072_text_iterator_example.rb} +30 -21
  162. data/lib/gtk_paradise/examples/gtk3/{057_image_example.rb → 073_image_example.rb} +1 -1
  163. data/lib/gtk_paradise/examples/gtk3/{058_frame_example.rb → 074_frame_example.rb} +1 -1
  164. data/lib/gtk_paradise/examples/gtk3/{059_gtk_expander.rb → 075_gtk_expander.rb} +2 -0
  165. data/lib/gtk_paradise/examples/gtk3/{060_ten_vboxes_example.rb → 076_ten_vboxes_example.rb} +21 -3
  166. data/lib/gtk_paradise/examples/gtk3/{063_button_box_example.rb → 077_button_box_example.rb} +11 -1
  167. data/lib/gtk_paradise/examples/gtk3/{064_tree_view_column_example.rb → 078_tree_view_column_example.rb} +2 -1
  168. data/lib/gtk_paradise/examples/gtk3/{065_tooltips_example.rb → 079_tooltips_example.rb} +14 -5
  169. data/lib/gtk_paradise/examples/gtk3/{066_vertical_boxes.rb → 080_vertical_boxes.rb} +2 -1
  170. data/lib/gtk_paradise/examples/gtk3/{067_vbox_with_spacing_and_border_width.rb → 081_vbox_with_spacing_and_border_width.rb} +2 -1
  171. data/lib/gtk_paradise/examples/gtk3/{069_file_chooser_dialog.rb → 082_file_chooser_dialog.rb} +3 -0
  172. data/lib/gtk_paradise/examples/gtk3/{070_bindings.rb → 083_bindings.rb} +15 -8
  173. data/lib/gtk_paradise/examples/gtk3/{072_recent_chooser_dialog.rb → 084_recent_chooser_dialog.rb} +2 -2
  174. data/lib/gtk_paradise/examples/gtk3/{073_showcase_the_cursors.rb → 085_showcase_the_cursors.rb} +30 -5
  175. data/lib/gtk_paradise/examples/gtk3/{074_app_chooser_button_example.rb → 086_app_chooser_button_example.rb} +1 -0
  176. data/lib/gtk_paradise/examples/gtk3/087_calendar_example.rb +41 -0
  177. data/lib/gtk_paradise/examples/gtk4/001_gtk_entry.rb +88 -0
  178. data/lib/gtk_paradise/examples/gtk4/002_scrolled_window_example.rb +62 -0
  179. data/lib/gtk_paradise/examples/gtk4/003_toggle_button_example.rb +23 -0
  180. data/lib/gtk_paradise/examples/gtk4/004_simple_dialog_example.rb +41 -0
  181. data/lib/gtk_paradise/examples/gtk4/005_spinner_example.rb +64 -0
  182. data/lib/gtk_paradise/examples/gtk4/006_text_view_example.rb +77 -0
  183. data/lib/gtk_paradise/examples/gtk4/007_two_windows_example.rb +55 -0
  184. data/lib/gtk_paradise/examples/gtk4/008_search_bar_example.rb +88 -0
  185. data/lib/gtk_paradise/examples/gtk4/009_text_view_example.rb +30 -0
  186. data/lib/gtk_paradise/examples/gtk4/010_switch_example.rb +52 -0
  187. data/lib/gtk_paradise/examples/gtk4/027_menubar_example.rb +35 -0
  188. data/lib/gtk_paradise/examples/gtk4/030_notebook_example.rb +83 -0
  189. data/lib/gtk_paradise/examples/gtk4/074_frame_example.rb +105 -0
  190. data/lib/gtk_paradise/examples/gtk4/076_ten_vboxes_example.rb +35 -0
  191. data/lib/gtk_paradise/examples/gtk4/087_calendar_example.rb +47 -0
  192. data/lib/gtk_paradise/examples/gtk4/100_changed_events_example.rb +77 -0
  193. data/lib/gtk_paradise/examples/gtk4/101_actionbar_example.rb +55 -0
  194. data/lib/gtk_paradise/examples/gtk4/102_picture_example.rb +35 -0
  195. data/lib/gtk_paradise/examples/gtk4/103_drawing_example.rb +101 -0
  196. data/lib/gtk_paradise/examples/gtk4/104_quit_on_keypress_event.rb +64 -0
  197. data/lib/gtk_paradise/examples/pango/pango_power.rb +1 -0
  198. data/lib/gtk_paradise/experimental/experimental.rb +3 -11
  199. data/lib/gtk_paradise/experimental/experimental_for_gtk4.rb +92 -0
  200. data/lib/gtk_paradise/fonts/fonts.rb +5 -1
  201. data/lib/gtk_paradise/gdk/cursor.rb +2 -2
  202. data/lib/gtk_paradise/{base_module/e.rb → gdk/event_crossing.rb} +6 -8
  203. data/lib/gtk_paradise/gdk/gdk.rb +1 -1
  204. data/lib/gtk_paradise/gtk_classes/about.rb +11 -2
  205. data/lib/gtk_paradise/gtk_classes/about_dialog.rb +6 -2
  206. data/lib/gtk_paradise/gtk_classes/alignment.rb +4 -1
  207. data/lib/gtk_paradise/gtk_classes/application.rb +94 -4
  208. data/lib/gtk_paradise/gtk_classes/application_window.rb +25 -0
  209. data/lib/gtk_paradise/gtk_classes/box.rb +131 -277
  210. data/lib/gtk_paradise/gtk_classes/button.rb +61 -40
  211. data/lib/gtk_paradise/gtk_classes/button_box.rb +9 -1
  212. data/lib/gtk_paradise/gtk_classes/cell_renderer_text.rb +5 -3
  213. data/lib/gtk_paradise/gtk_classes/check_button.rb +48 -12
  214. data/lib/gtk_paradise/gtk_classes/combo_box.rb +22 -15
  215. data/lib/gtk_paradise/gtk_classes/combo_box_entry.rb +17 -11
  216. data/lib/gtk_paradise/gtk_classes/combo_box_text.rb +30 -25
  217. data/lib/gtk_paradise/gtk_classes/dialog.rb +2 -2
  218. data/lib/gtk_paradise/gtk_classes/entry.rb +281 -126
  219. data/lib/gtk_paradise/gtk_classes/entry_completion.rb +15 -8
  220. data/lib/gtk_paradise/gtk_classes/event_box.rb +21 -2
  221. data/lib/gtk_paradise/gtk_classes/event_button.rb +1 -1
  222. data/lib/gtk_paradise/gtk_classes/expander.rb +8 -1
  223. data/lib/gtk_paradise/gtk_classes/file_chooser_dialog.rb +1 -1
  224. data/lib/gtk_paradise/gtk_classes/file_filter.rb +4 -2
  225. data/lib/gtk_paradise/gtk_classes/file_selection.rb +4 -3
  226. data/lib/gtk_paradise/gtk_classes/frame.rb +25 -5
  227. data/lib/gtk_paradise/gtk_classes/grid.rb +343 -153
  228. data/lib/gtk_paradise/gtk_classes/hbox.rb +145 -0
  229. data/lib/gtk_paradise/gtk_classes/header_bar.rb +20 -8
  230. data/lib/gtk_paradise/gtk_classes/image.rb +5 -3
  231. data/lib/gtk_paradise/gtk_classes/label.rb +201 -145
  232. data/lib/gtk_paradise/gtk_classes/list_store.rb +13 -0
  233. data/lib/gtk_paradise/gtk_classes/menu.rb +7 -3
  234. data/lib/gtk_paradise/gtk_classes/menu_bar.rb +1 -1
  235. data/lib/gtk_paradise/gtk_classes/menu_item.rb +1 -1
  236. data/lib/gtk_paradise/gtk_classes/notebook.rb +173 -72
  237. data/lib/gtk_paradise/gtk_classes/paned.rb +52 -0
  238. data/lib/gtk_paradise/gtk_classes/radio_menu_item.rb +26 -1
  239. data/lib/gtk_paradise/gtk_classes/scale_button.rb +16 -1
  240. data/lib/gtk_paradise/gtk_classes/scrolled_window.rb +16 -6
  241. data/lib/gtk_paradise/gtk_classes/search_bar.rb +1 -1
  242. data/lib/gtk_paradise/gtk_classes/source_buffer.rb +4 -5
  243. data/lib/gtk_paradise/gtk_classes/spin_button.rb +35 -13
  244. data/lib/gtk_paradise/gtk_classes/spinner.rb +32 -2
  245. data/lib/gtk_paradise/gtk_classes/status_icon.rb +2 -0
  246. data/lib/gtk_paradise/gtk_classes/statusbar.rb +1 -0
  247. data/lib/gtk_paradise/gtk_classes/style_context.rb +71 -0
  248. data/lib/gtk_paradise/gtk_classes/text_buffer.rb +52 -19
  249. data/lib/gtk_paradise/gtk_classes/text_view.rb +54 -11
  250. data/lib/gtk_paradise/gtk_classes/toggle_button.rb +3 -0
  251. data/lib/gtk_paradise/gtk_classes/toolbar.rb +2 -2
  252. data/lib/gtk_paradise/gtk_classes/tree_iter.rb +1 -1
  253. data/lib/gtk_paradise/gtk_classes/tree_view.rb +101 -70
  254. data/lib/gtk_paradise/gtk_classes/tree_view_column.rb +2 -1
  255. data/lib/gtk_paradise/gtk_classes/vbox.rb +71 -10
  256. data/lib/gtk_paradise/gtk_classes/vscale.rb +2 -2
  257. data/lib/gtk_paradise/gtk_classes/widget.rb +1158 -646
  258. data/lib/gtk_paradise/gtk_classes/window.rb +37 -2
  259. data/lib/gtk_paradise/hello_world/README.md +1 -1
  260. data/lib/gtk_paradise/hello_world/hello_world_gtk4.rb +20 -0
  261. data/lib/gtk_paradise/images/icons/close_image.png +0 -0
  262. data/lib/gtk_paradise/images/icons/closed.png +0 -0
  263. data/lib/gtk_paradise/images/icons/directory.png +0 -0
  264. data/lib/gtk_paradise/images/icons/icon_cool.gif +0 -0
  265. data/lib/gtk_paradise/images/icons/icon_lol.gif +0 -0
  266. data/lib/gtk_paradise/images/icons/icon_smile.gif +0 -0
  267. data/lib/gtk_paradise/images/icons/opened.png +0 -0
  268. data/lib/gtk_paradise/images/internal/gtk_label_example.png +0 -0
  269. data/lib/gtk_paradise/images/internal/gtk_tree_view1.png +0 -0
  270. data/lib/gtk_paradise/images/misc/minus_symbol.png +0 -0
  271. data/lib/gtk_paradise/images/misc/plus_symbol.png +0 -0
  272. data/lib/gtk_paradise/images/misc/wiki_logo.png +0 -0
  273. data/lib/gtk_paradise/images/small/GREEN_CIRCLE.png +0 -0
  274. data/lib/gtk_paradise/images/small/README.md +2 -0
  275. data/lib/gtk_paradise/images/small/RED_CIRCLE.png +0 -0
  276. data/lib/gtk_paradise/pango/{pango_fonts.rb → fonts.rb} +2 -2
  277. data/lib/gtk_paradise/pango/{pango.rb → layout.rb} +1 -1
  278. data/lib/gtk_paradise/pango/pango_renderer.rb +9 -2
  279. data/lib/gtk_paradise/project/project.rb +4 -3
  280. data/lib/gtk_paradise/prototypes/README.md +8 -0
  281. data/lib/gtk_paradise/prototypes/gtk3_standalone.rb +8 -21
  282. data/lib/gtk_paradise/prototypes/gtk4_standalone.rb +135 -0
  283. data/lib/gtk_paradise/prototypes/shared_code.rb +9 -17
  284. data/lib/gtk_paradise/prototypes/unified_gtk_prototype.rb +179 -0
  285. data/lib/gtk_paradise/require_gir_ffi_gtk3.rb +3 -0
  286. data/lib/gtk_paradise/require_gtk4.rb +7 -0
  287. data/lib/gtk_paradise/requires/require_base_module.rb +7 -0
  288. data/lib/gtk_paradise/requires/require_files_irrespective_of_the_gtk_version_at_hand.rb +26 -16
  289. data/lib/gtk_paradise/requires/require_gtk2.rb +6 -4
  290. data/lib/gtk_paradise/requires/{require_gtk2_or_gtk3.rb → require_gtk2_or_gtk3_or_gtk4.rb} +33 -12
  291. data/lib/gtk_paradise/requires/require_gtk3.rb +5 -20
  292. data/lib/gtk_paradise/requires/require_gtk4.rb +13 -0
  293. data/lib/gtk_paradise/requires/require_gtk_runner.rb +1 -0
  294. data/lib/gtk_paradise/requires/require_the_base_module_and_gtk_run.rb +1 -1
  295. data/lib/gtk_paradise/requires/require_the_base_module_the_app_module_and_the_toplevel_methods.rb +9 -0
  296. data/lib/gtk_paradise/requires/require_the_classes_files_for_gtk4.rb +11 -0
  297. data/lib/gtk_paradise/requires/require_the_colours_gem.rb +9 -0
  298. data/lib/gtk_paradise/requires/require_the_default_gtk_version.rb +4 -2
  299. data/lib/gtk_paradise/requires/require_the_toplevel_methods.rb +1 -1
  300. data/lib/gtk_paradise/run.rb +1 -0
  301. data/lib/gtk_paradise/run_this_widget/run_this_widget.rb +7 -3
  302. data/lib/gtk_paradise/threads/threads.rb +15 -10
  303. data/lib/gtk_paradise/toplevel_methods/css.rb +183 -35
  304. data/lib/gtk_paradise/toplevel_methods/cursor.rb +17 -3
  305. data/lib/gtk_paradise/toplevel_methods/determine_which_gtk_version_is_in_use.rb +90 -8
  306. data/lib/gtk_paradise/toplevel_methods/events.rb +6 -0
  307. data/lib/gtk_paradise/toplevel_methods/keys.rb +1 -1
  308. data/lib/gtk_paradise/toplevel_methods/screen_resolution.rb +32 -5
  309. data/lib/gtk_paradise/toplevel_methods/text_buffer_tags.rb +13 -4
  310. data/lib/gtk_paradise/toplevel_methods/tokenizer.rb +18 -3
  311. data/lib/gtk_paradise/toplevel_methods/{misc.rb → toplevel_methods.rb} +810 -258
  312. data/lib/gtk_paradise/utility_scripts/commandline_to_automatic_gui.rb +244 -0
  313. data/lib/gtk_paradise/version/version.rb +2 -2
  314. data/lib/gtk_paradise/widgets/gtk2/cat_merge.rb +2 -6
  315. data/lib/gtk_paradise/widgets/gtk2/cell_renderer_progress_example.rb +0 -5
  316. data/lib/gtk_paradise/widgets/gtk2/foto_lister.rb +4 -8
  317. data/lib/gtk_paradise/widgets/gtk2/gidnight_commander/gidnight_commander.rb +3 -3
  318. data/lib/gtk_paradise/widgets/gtk2/hbox_example.rb +1 -5
  319. data/lib/gtk_paradise/widgets/gtk2/multiple_select_in_a_tree_view_widget.rb +2 -6
  320. data/lib/gtk_paradise/widgets/gtk2/paned_example.rb +1 -1
  321. data/lib/gtk_paradise/widgets/gtk2/slider_changing_button.rb +2 -6
  322. data/lib/gtk_paradise/widgets/gtk2/status_icon_example.rb +2 -6
  323. data/lib/gtk_paradise/widgets/gtk2/table2.rb +2 -6
  324. data/lib/gtk_paradise/widgets/gtk2/toolbar_example.rb +2 -6
  325. data/lib/gtk_paradise/widgets/{version_agnostic → gtk3/audio_button}/audio_button.rb +19 -30
  326. data/lib/gtk_paradise/widgets/gtk3/burn_this_iso_file/burn_this_iso_file.rb +2 -6
  327. data/lib/gtk_paradise/widgets/{version_agnostic → gtk3/button_open_remote_webpage}/button_open_remote_webpage.rb +105 -50
  328. data/lib/gtk_paradise/widgets/gtk3/button_with_border/button_with_border.rb +155 -0
  329. data/lib/gtk_paradise/widgets/{version_agnostic → gtk3/button_xorg_buffer}/button_xorg_buffer.rb +76 -18
  330. data/lib/gtk_paradise/widgets/gtk3/calculator/calculator.rb +58 -336
  331. data/lib/gtk_paradise/widgets/gtk3/checkbox_image/checkbox_image.rb +3 -7
  332. data/lib/gtk_paradise/widgets/{version_agnostic → gtk3/coloured_button}/coloured_button.rb +94 -24
  333. data/lib/gtk_paradise/widgets/gtk3/coloured_square/coloured_square.rb +2 -6
  334. data/lib/gtk_paradise/widgets/gtk3/coloured_unit/coloured_unit.rb +151 -0
  335. data/lib/gtk_paradise/widgets/gtk3/cpu_widget/cpu_widget.rb +2 -6
  336. data/lib/gtk_paradise/widgets/gtk3/directory_content_widget/directory_content_widget.rb +937 -7
  337. data/lib/gtk_paradise/widgets/gtk3/editor/connect_skeleton.rb +34 -39
  338. data/lib/gtk_paradise/widgets/gtk3/editor/create.rb +67 -42
  339. data/lib/gtk_paradise/widgets/gtk3/editor/editor.rb +257 -274
  340. data/lib/gtk_paradise/widgets/gtk3/editor/internal_widgets/goto_line_widget.rb +53 -69
  341. data/lib/gtk_paradise/widgets/gtk3/editor/misc.rb +359 -112
  342. data/lib/gtk_paradise/widgets/gtk3/files_in_directory/files_in_directory.rb +2 -7
  343. data/lib/gtk_paradise/widgets/gtk3/flexible_vte/flexible_vte.rb +9 -26
  344. data/lib/gtk_paradise/widgets/gtk3/font_size_widget/action_button.rb +1 -5
  345. data/lib/gtk_paradise/widgets/gtk3/font_size_widget/font_size_widget.rb +2 -6
  346. data/lib/gtk_paradise/widgets/gtk3/four_components_entry/four_components_entry.rb +353 -0
  347. data/lib/gtk_paradise/widgets/{gtk2 → gtk3}/gidnight_commander/gidnight_commander.config +1 -2
  348. data/lib/gtk_paradise/widgets/gtk3/gidnight_commander/gidnight_commander.rb +165 -125
  349. data/lib/gtk_paradise/widgets/gtk3/image_close_on_click_action/image_close_on_click_action.rb +34 -2
  350. data/lib/gtk_paradise/widgets/gtk3/image_viewer/image_viewer.rb +23 -26
  351. data/lib/gtk_paradise/widgets/gtk3/information_about_the_harddisc/harddisc_information.rb +161 -0
  352. data/lib/gtk_paradise/widgets/gtk3/insert_character/insert_character.rb +24 -29
  353. data/lib/gtk_paradise/widgets/gtk3/keyboard/keyboard.rb +378 -0
  354. data/lib/gtk_paradise/widgets/gtk3/linux_users/linux_users.rb +35 -38
  355. data/lib/gtk_paradise/widgets/gtk3/my_calendar/my_calendar.rb +330 -7
  356. data/lib/gtk_paradise/widgets/gtk3/my_image_menu_item/my_image_menu_item.rb +179 -0
  357. data/lib/gtk_paradise/widgets/gtk3/non_numbers_only/non_numbers_only.rb +136 -0
  358. data/lib/gtk_paradise/widgets/gtk3/note_window/note_window.rb +199 -0
  359. data/lib/gtk_paradise/widgets/gtk3/notebook_controller/notebook_controller.rb +325 -7
  360. data/lib/gtk_paradise/widgets/gtk3/notebook_tab_with_icon/notebook_tab_with_icon.rb +469 -7
  361. data/lib/gtk_paradise/widgets/gtk3/notebook_with_storage_functionality/notebook_with_storage_functionality.rb +180 -0
  362. data/lib/gtk_paradise/widgets/gtk3/numbered_lines/numbered_lines.rb +241 -107
  363. data/lib/gtk_paradise/widgets/{version_agnostic → gtk3/numbers_only}/numbers_only.rb +15 -3
  364. data/lib/gtk_paradise/widgets/gtk3/ping_widget/ping_widget.rb +491 -8
  365. data/lib/gtk_paradise/widgets/gtk3/regex_matcher/regex_matcher.rb +363 -47
  366. data/lib/gtk_paradise/widgets/gtk3/rename_widget/rename_widget.rb +8 -25
  367. data/lib/gtk_paradise/widgets/gtk3/show_which_key_was_pressed/show_which_key_was_pressed.rb +190 -0
  368. data/lib/gtk_paradise/widgets/gtk3/stopwatch/stopwatch.rb +318 -7
  369. data/lib/gtk_paradise/widgets/gtk3/sys_message/sys_message.rb +219 -7
  370. data/lib/gtk_paradise/widgets/gtk3/system_information/system_information.rb +58 -34
  371. data/lib/gtk_paradise/widgets/gtk3/tabble/admin_panel.rb +2 -6
  372. data/lib/gtk_paradise/widgets/gtk3/tabble/image_and_button.rb +3 -7
  373. data/lib/gtk_paradise/widgets/gtk3/tabble/tabble.rb +2 -6
  374. data/lib/gtk_paradise/widgets/gtk3/type_trainer/type_trainer.rb +182 -0
  375. data/lib/gtk_paradise/widgets/gtk3/view_webpage/view_webpage.rb +2 -6
  376. data/lib/gtk_paradise/widgets/gtk3/widget_switcher/widget_switcher.rb +240 -0
  377. data/lib/gtk_paradise/widgets/gtk3/wiki/README.md +4 -0
  378. data/lib/gtk_paradise/widgets/gtk3/wiki/wiki.rb +445 -0
  379. data/lib/gtk_paradise/widgets/gtk4/ping_widget/ping_widget.rb +4 -0
  380. data/lib/gtk_paradise/widgets/gtk4/show_icon_theme/show_icon_theme.rb +134 -0
  381. data/lib/gtk_paradise/widgets/gtk4/sys_message/sys_message.rb +269 -0
  382. data/lib/gtk_paradise/widgets/{gtk2/sys_message/sys_message.rb → gtk4/xpm_loader/xpm_loader.rb} +13 -10
  383. data/lib/gtk_paradise/widgets/shared_code/browser/browser_module.rb +4 -16
  384. data/lib/gtk_paradise/widgets/shared_code/calculator/calculator_module.rb +581 -0
  385. data/lib/gtk_paradise/widgets/shared_code/cdripper/cdripper_module.rb +1 -1
  386. data/lib/gtk_paradise/widgets/shared_code/colour_filled_widget/colour_filled_widget_module.rb +25 -28
  387. data/lib/gtk_paradise/widgets/shared_code/colour_palette/colour_palette_module.rb +2 -2
  388. data/lib/gtk_paradise/widgets/shared_code/contacts/contacts_module.rb +62 -64
  389. data/lib/gtk_paradise/widgets/shared_code/file_viewer/file_viewer_module.rb +3 -3
  390. data/lib/gtk_paradise/widgets/shared_code/flip_state_widget/flip_state_widget_module.rb +3 -19
  391. data/lib/gtk_paradise/widgets/shared_code/information_about_the_harddisc/harddisc_information.rb +0 -155
  392. data/lib/gtk_paradise/widgets/shared_code/information_about_the_harddisc/information_about_the_harddisc_module.rb +0 -444
  393. data/lib/gtk_paradise/widgets/shared_code/lsmod/lsmod_module.rb +22 -26
  394. data/lib/gtk_paradise/widgets/shared_code/lspci/lspci_module.rb +24 -36
  395. data/lib/gtk_paradise/widgets/shared_code/maximize_button/maximize_button_module.rb +2 -7
  396. data/lib/gtk_paradise/widgets/shared_code/mini_clock/mini_clock_module.rb +133 -76
  397. data/lib/gtk_paradise/widgets/shared_code/my_calendar/my_calendar_module.rb +0 -327
  398. data/lib/gtk_paradise/widgets/shared_code/pid_displayer/pid_displayer_module.rb +53 -41
  399. data/lib/gtk_paradise/widgets/shared_code/random_image/random_image_module.rb +46 -29
  400. data/lib/gtk_paradise/widgets/shared_code/select_file/select_file_module.rb +1 -1
  401. data/lib/gtk_paradise/widgets/shared_code/show_icon_theme/show_icon_theme_module.rb +59 -46
  402. data/lib/gtk_paradise/widgets/shared_code/simple_clock/simple_clock_module.rb +1 -12
  403. data/lib/gtk_paradise/widgets/shared_code/stopwatch/stopwatch_module.rb +0 -341
  404. data/lib/gtk_paradise/widgets/shared_code/sys_message/sys_message_module.rb +0 -211
  405. data/lib/gtk_paradise/widgets/shared_code/tabby/tabby_module.rb +3 -15
  406. data/lib/gtk_paradise/widgets/shared_code/xpm_loader/xpm_loader_module.rb +15 -23
  407. data/lib/gtk_paradise/www/index.cgi +2 -2
  408. data/lib/gtk_paradise/yaml/browser_URLs.yml +3 -4
  409. data/lib/gtk_paradise/yaml/configuration_options_for_class_gtk_runner.yml +6 -6
  410. data/lib/gtk_paradise/yaml/experimental/README.md +3 -0
  411. data/lib/gtk_paradise/yaml/experimental/all_widgets.yml +37 -0
  412. data/lib/gtk_paradise/yaml/menu.yml +6 -3
  413. data/lib/gtk_paradise/yaml/notebook_controller.yml +62 -29
  414. data/lib/gtk_paradise.rb +1 -1
  415. data/test/gtk2/testing_combo_box.rb +1 -0
  416. data/test/gtk2/testing_display.rb +23 -0
  417. data/test/gtk2/testing_gtk_image.rb +4 -3
  418. data/test/gtk2/testing_hbox_and_vbox.rb +37 -0
  419. data/test/gtk2/testing_label_with_ampersand.rb +5 -2
  420. data/test/gtk2/testing_notebook.rb +11 -5
  421. data/test/gtk3/test_widget.rb +2 -1
  422. data/test/gtk3/testing_app.rb +0 -1
  423. data/test/gtk3/testing_base_module.rb +2 -1
  424. data/test/gtk3/testing_numbered_lines.rb +20 -0
  425. data/test/gtk3/testing_project_base_directory.rb +6 -1
  426. data/test/gtk3/testing_the_html_pseudo_tags.rb +2 -2
  427. data/test/gtk4/testing_gtk_entry.rb +24 -0
  428. data/test/misc/testing_a_gtk_frame.rb +14 -0
  429. data/test/misc/testing_gtk4_simplifications.rb +105 -0
  430. data/test/misc/testing_gtk_paradise_runner.rb +19 -4
  431. data/test/misc/testing_numbered_lines.rb +36 -0
  432. data/test/misc/testing_the_gtk_classes.rb +83 -0
  433. metadata +266 -198
  434. data/lib/gtk_paradise/base_module/change_directory.rb +0 -22
  435. data/lib/gtk_paradise/base_module/combo_box_and_combo_box_entry.rb +0 -113
  436. data/lib/gtk_paradise/base_module/commandline_arguments.rb +0 -36
  437. data/lib/gtk_paradise/base_module/configuration.rb +0 -50
  438. data/lib/gtk_paradise/base_module/constants.rb +0 -23
  439. data/lib/gtk_paradise/base_module/debug.rb +0 -127
  440. data/lib/gtk_paradise/base_module/draggable.rb +0 -95
  441. data/lib/gtk_paradise/base_module/emoji.rb +0 -107
  442. data/lib/gtk_paradise/base_module/esystem.rb +0 -22
  443. data/lib/gtk_paradise/base_module/events.rb +0 -111
  444. data/lib/gtk_paradise/base_module/fonts.rb +0 -119
  445. data/lib/gtk_paradise/base_module/graphics_display.rb +0 -47
  446. data/lib/gtk_paradise/base_module/gtk3.rb +0 -43
  447. data/lib/gtk_paradise/base_module/gtk_buttons.rb +0 -562
  448. data/lib/gtk_paradise/base_module/gtk_entry.rb +0 -126
  449. data/lib/gtk_paradise/base_module/gtk_fixed.rb +0 -18
  450. data/lib/gtk_paradise/base_module/gtk_grid.rb +0 -61
  451. data/lib/gtk_paradise/base_module/gtk_image.rb +0 -501
  452. data/lib/gtk_paradise/base_module/gtk_label.rb +0 -211
  453. data/lib/gtk_paradise/base_module/gtk_notebook.rb +0 -88
  454. data/lib/gtk_paradise/base_module/gtk_scrolled_window.rb +0 -155
  455. data/lib/gtk_paradise/base_module/misc.rb +0 -2949
  456. data/lib/gtk_paradise/base_module/pango.rb +0 -24
  457. data/lib/gtk_paradise/base_module/popover.rb +0 -241
  458. data/lib/gtk_paradise/base_module/register_sigint.rb +0 -20
  459. data/lib/gtk_paradise/base_module/reset.rb +0 -128
  460. data/lib/gtk_paradise/base_module/return_corresponding_gtk_stock_item.rb +0 -92
  461. data/lib/gtk_paradise/base_module/roebe.rb +0 -19
  462. data/lib/gtk_paradise/base_module/table.rb +0 -438
  463. data/lib/gtk_paradise/base_module/time.rb +0 -35
  464. data/lib/gtk_paradise/constants/available_cursors.rb +0 -52
  465. data/lib/gtk_paradise/constants/fonts.rb +0 -38
  466. data/lib/gtk_paradise/constants/misc.rb +0 -56
  467. data/lib/gtk_paradise/constants/newline.rb +0 -14
  468. data/lib/gtk_paradise/constants/xbm_icons.rb +0 -121
  469. data/lib/gtk_paradise/examples/gtk3/003_sorted_tree.rb +0 -141
  470. data/lib/gtk_paradise/examples/gtk3/034_combo_box_example.rb +0 -49
  471. data/lib/gtk_paradise/examples/gtk3/068_text_view_example.rb +0 -34
  472. data/lib/gtk_paradise/examples/gtk3/071_search_bar_example.rb +0 -59
  473. data/lib/gtk_paradise/gtk_classes/colours/colours.rb +0 -158
  474. data/lib/gtk_paradise/requires/require_the_minesweeper_files.rb +0 -11
  475. data/lib/gtk_paradise/toplevel_methods/allow_only_numbers.rb +0 -59
  476. data/lib/gtk_paradise/toplevel_methods/csv.rb +0 -102
  477. data/lib/gtk_paradise/toplevel_methods/e.rb +0 -18
  478. data/lib/gtk_paradise/toplevel_methods/enable_and_disable_warnings.rb +0 -58
  479. data/lib/gtk_paradise/toplevel_methods/keyboard.rb +0 -25
  480. data/lib/gtk_paradise/toplevel_methods/main_file.rb +0 -31
  481. data/lib/gtk_paradise/toplevel_methods/register_sigint.rb +0 -17
  482. data/lib/gtk_paradise/toplevel_methods/roebe.rb +0 -22
  483. data/lib/gtk_paradise/toplevel_methods/select_file.rb +0 -168
  484. data/lib/gtk_paradise/toplevel_methods/spacer.rb +0 -55
  485. data/lib/gtk_paradise/toplevel_methods/tooltips.rb +0 -71
  486. data/lib/gtk_paradise/toplevel_methods/we_use_this_gtk_version.rb +0 -65
  487. data/lib/gtk_paradise/widgets/gtk2/directory_content_widget/directory_content_widget.rb +0 -30
  488. data/lib/gtk_paradise/widgets/gtk2/my_calendar/my_calendar.config +0 -6
  489. data/lib/gtk_paradise/widgets/gtk2/my_calendar/my_calendar.rb +0 -34
  490. data/lib/gtk_paradise/widgets/gtk2/notebook_tab_with_icon/notebook_tab_with_icon.rb +0 -30
  491. data/lib/gtk_paradise/widgets/gtk2/ping_widget/ping_widget.rb +0 -30
  492. data/lib/gtk_paradise/widgets/gtk2/stopwatch/stopwatch.rb +0 -30
  493. data/lib/gtk_paradise/widgets/gtk2/sys_message/sys_message.config +0 -6
  494. data/lib/gtk_paradise/widgets/shared_code/directory_content_widget/constants.rb +0 -53
  495. data/lib/gtk_paradise/widgets/shared_code/directory_content_widget/directory_content_widget_module.rb +0 -777
  496. data/lib/gtk_paradise/widgets/shared_code/directory_content_widget/handle_this_file_or_symlink.rb +0 -83
  497. data/lib/gtk_paradise/widgets/shared_code/notebook_controller/notebook_controller_module.rb +0 -339
  498. data/lib/gtk_paradise/widgets/shared_code/notebook_tab_with_icon/notebook_tab_with_icon_module.rb +0 -297
  499. data/lib/gtk_paradise/widgets/shared_code/ping_widget/ping_widget_module.rb +0 -326
  500. data/lib/gtk_paradise/widgets/version_agnostic/button_with_border.rb +0 -63
  501. data/lib/gtk_paradise/widgets/version_agnostic/coloured_unit.rb +0 -54
  502. data/lib/gtk_paradise/widgets/version_agnostic/my_image_menu_item.rb +0 -103
  503. data/lib/gtk_paradise/widgets/version_agnostic/my_menu_item_separator.rb +0 -31
  504. data/lib/gtk_paradise/widgets/version_agnostic/non_numbers_only.rb +0 -66
  505. data/lib/gtk_paradise/widgets/version_agnostic/note_window.rb +0 -107
  506. /data/lib/gtk_paradise/examples/gtk3/{084_undecorated_window_example.rb → 014_undecorated_window_example.rb} +0 -0
  507. /data/lib/gtk_paradise/examples/gtk3/{077_status_icon_example.rb → 019_status_icon_example.rb} +0 -0
  508. /data/lib/gtk_paradise/examples/gtk3/{076_stack_example.rb → 020_stack_example.rb} +0 -0
  509. /data/lib/gtk_paradise/examples/gtk3/{006_password_example.rb → 025_password_example.rb} +0 -0
  510. /data/lib/gtk_paradise/examples/gtk3/{015_list_box_example.rb → 033_list_box_example.rb} +0 -0
  511. /data/lib/gtk_paradise/examples/gtk3/{021_scale_button_demo.rb → 039_scale_button_demo.rb} +0 -0
  512. /data/lib/gtk_paradise/examples/gtk3/{024_installation_assistant.rb → 042_installation_assistant.rb} +0 -0
  513. /data/lib/gtk_paradise/examples/gtk3/{040_font_chooser_dialog_example.rb → 056_font_chooser_dialog_example.rb} +0 -0
  514. /data/lib/gtk_paradise/examples/gtk3/{041_flowbox.rb → 057_flowbox.rb} +0 -0
  515. /data/lib/gtk_paradise/examples/gtk3/{045_fixed_example.rb → 061_fixed_example.rb} +0 -0
  516. /data/lib/gtk_paradise/examples/gtk3/{054_svg_viewer.rb → 070_svg_viewer.rb} +0 -0
@@ -3,28 +3,490 @@
3
3
  # frozen_string_literal: true
4
4
  # =========================================================================== #
5
5
  # === Gtk::NotebookTabWithIcon
6
+ #
7
+ # This class represents a widget that can be put into notebooks, which
8
+ # have a little icon, typically on their left side on top.
9
+ #
10
+ # As example, you can pick among the following to do a tab:
11
+ #
12
+ # Gtk::NotebookTabWithIcon.new # picks default
13
+ # Gtk::NotebookTabWithIcon.new('rand')
14
+ # Gtk::NotebookTabWithIcon.new('some/path/file.png')
15
+ #
6
16
  # =========================================================================== #
7
17
  # require 'gtk_paradise/widgets/gtk3/notebook_tab_with_icon/notebook_tab_with_icon.rb'
8
- # Gtk::NotebookTabWithIcon.new(:tabble, 'Here is the original label.')
18
+ # ::Gtk::NotebookTabWithIcon.new(:tabble, 'Here is the original label.', &block)
19
+ # Gtk::NotebookTabWithIcon.run
9
20
  # =========================================================================== #
10
21
  require 'gtk_paradise/require_gtk3'
11
22
 
12
23
  module Gtk
13
24
 
14
- class NotebookTabWithIcon < ::Gtk::Box
25
+ class NotebookTabWithIcon < ::Gtk::BaseModuleBox # === Gtk::NotebookTabWithIcon
15
26
 
16
- require 'gtk_paradise/widgets/shared_code/notebook_tab_with_icon/notebook_tab_with_icon_module.rb'
17
- include ::Gtk::NotebookTabWithIconModule
27
+ # ========================================================================= #
28
+ # === TITLE
29
+ # ========================================================================= #
30
+ TITLE = 'Notebook-Tab with icon'
31
+
32
+ # ========================================================================= #
33
+ # === WIDTH
34
+ # ========================================================================= #
35
+ WIDTH = '4% or minimum 60px'
36
+
37
+ # ========================================================================= #
38
+ # === HEIGHT
39
+ # ========================================================================= #
40
+ HEIGHT = '4% or minimum 35px'
41
+
42
+ # ========================================================================= #
43
+ # === USE_THIS_FONT
44
+ # ========================================================================= #
45
+ USE_THIS_FONT = :dejavu_condensed_12
46
+
47
+ # ========================================================================= #
48
+ # === initialize
49
+ #
50
+ # Four input-arguments can be provided. Their meaning is:
51
+ #
52
+ # (1) location_of_the_image # The location to the image that you wish to use.
53
+ # (2) label_title # The title of the label, appearing next to the image
54
+ # (3) text_colour # The colour of the label
55
+ # (4) can_focus # whether the user can select (focus) on it
56
+ #
57
+ # ========================================================================= #
58
+ def initialize(
59
+ location_of_the_image = :small_shield,
60
+ label_title = '',
61
+ text_colour = 'black',
62
+ can_focus = false,
63
+ run_already = true,
64
+ &block
65
+ )
66
+ super(:horizontal)
67
+ reset
68
+ set_label_title(label_title)
69
+ set_text_colour(text_colour)
70
+ set_location_of_the_image(
71
+ location_of_the_image
72
+ )
73
+ # ======================================================================= #
74
+ # === Handle blocks next
75
+ # ======================================================================= #
76
+ if block_given?
77
+ yielded = yield
78
+ # ===================================================================== #
79
+ # === Handle hashes next
80
+ # ===================================================================== #
81
+ if yielded.is_a? Hash
82
+ # =================================================================== #
83
+ # === :text_colour
84
+ # =================================================================== #
85
+ if yielded.has_key? :text_colour
86
+ set_text_colour(yielded[:text_colour])
87
+ end
88
+ # =================================================================== #
89
+ # === :use_close_image
90
+ # =================================================================== #
91
+ if yielded.has_key? :use_close_image
92
+ use_close_image if yielded[:use_close_image]
93
+ end
94
+ # =================================================================== #
95
+ # === :placement
96
+ # =================================================================== #
97
+ if yielded.has_key? :placement
98
+ @placement = yielded.delete(:placement)
99
+ end
100
+ elsif yielded.is_a? Symbol
101
+ case yielded
102
+ # =================================================================== #
103
+ # === :right_side
104
+ # =================================================================== #
105
+ when :right_side
106
+ set_placement(:right)
107
+ end
108
+ end
109
+ end
110
+ run if run_already
111
+ end
112
+
113
+ # ========================================================================= #
114
+ # === reset (reset tag)
115
+ # ========================================================================= #
116
+ def reset
117
+ reset_the_internal_variables
118
+ infer_the_namespace
119
+ # ======================================================================= #
120
+ # === @configuration
121
+ # ======================================================================= #
122
+ @configuration = [true, __dir__, namespace?]
123
+ # ======================================================================= #
124
+ # === Set the title, width, height and the font in use.
125
+ # ======================================================================= #
126
+ title_width_height_font(TITLE, WIDTH, HEIGHT, USE_THIS_FONT)
127
+ use_gtk_paradise_project_css_file
128
+ infer_the_size_automatically
129
+ # ======================================================================= #
130
+ # === @placement
131
+ # ======================================================================= #
132
+ set_placement(:left)
133
+ # ======================================================================= #
134
+ # === @image
135
+ # ======================================================================= #
136
+ @image = nil
137
+ # ======================================================================= #
138
+ # === @background_colour
139
+ # ======================================================================= #
140
+ @background_colour = :very_light_grey # :lightgrey # :white
141
+ end
142
+
143
+ # ========================================================================= #
144
+ # === set_label_title
145
+ # ========================================================================= #
146
+ def set_label_title(i)
147
+ @label_title = i
148
+ end
149
+
150
+ # ========================================================================= #
151
+ # === label_title?
152
+ # ========================================================================= #
153
+ def label_title?
154
+ @label_title
155
+ end; alias label_text? label_title? # === label_text?
156
+
157
+ # ========================================================================= #
158
+ # === set_placement
159
+ # ========================================================================= #
160
+ def set_placement(i = :right)
161
+ @placement = i.to_sym
162
+ end
163
+
164
+ # ========================================================================= #
165
+ # === placement?
166
+ # ========================================================================= #
167
+ def placement?
168
+ @placement
169
+ end
170
+
171
+ # ========================================================================= #
172
+ # === create_the_image
173
+ #
174
+ # This will assign to the variable called @image.
175
+ # ========================================================================= #
176
+ def create_the_image
177
+ @image = create_image
178
+ @image.set_padding(3, 1)
179
+ end
180
+
181
+ # ========================================================================= #
182
+ # === change_location_of_the_image_and_icon
183
+ # ========================================================================= #
184
+ def change_location_of_the_image_and_icon(
185
+ i = @location_of_the_image
186
+ )
187
+ change_location_of_the_image(i)
188
+ change_icon(i)
189
+ end
190
+
191
+ # ========================================================================= #
192
+ # === set_text_colour
193
+ # ========================================================================= #
194
+ def set_text_colour(i)
195
+ @text_colour = i
196
+ end
197
+
198
+ # ========================================================================= #
199
+ # === set_location_of_the_image
200
+ # ========================================================================= #
201
+ def set_location_of_the_image(i = :default)
202
+ case i
203
+ # ======================================================================= #
204
+ # === :tabble
205
+ # ======================================================================= #
206
+ when :tabble,
207
+ :default
208
+ i = '/home/x/data/images/linux/TABBLE.png'
209
+ # ======================================================================= #
210
+ # === small_shield
211
+ # ======================================================================= #
212
+ when :small_shield
213
+ i = project_base_directory?+
214
+ 'images/misc/small_shield.png'
215
+ end
216
+ @location_of_the_image = i # gi $MY_USERS/x/DATA/IMG/RPG/STD/SMALL_SHIELD.png
217
+ end
218
+
219
+ # ========================================================================= #
220
+ # === update_icon
221
+ #
222
+ # With this you can update the icon. It will always point to @location_of_the_image
223
+ # ========================================================================= #
224
+ def update_icon(
225
+ i = @location_of_the_image
226
+ )
227
+ if File.exist? i
228
+ @image.set_file(i)
229
+ else
230
+ puts "No file exists at `#{i}`."
231
+ end
232
+ end
233
+
234
+ # ========================================================================= #
235
+ # === padding?
236
+ # ========================================================================= #
237
+ def padding?
238
+ 4
239
+ end
240
+
241
+ # ========================================================================= #
242
+ # === border_size?
243
+ # ========================================================================= #
244
+ def border_size?
245
+ 2
246
+ end
247
+
248
+ # ========================================================================= #
249
+ # === set_tab_pos
250
+ # ========================================================================= #
251
+ def set_tab_pos(i)
252
+ super(i)
253
+ end
254
+
255
+ # ========================================================================= #
256
+ # === create_the_grid
257
+ # ========================================================================= #
258
+ def create_the_grid
259
+ # ======================================================================= #
260
+ # === @grid
261
+ # ======================================================================= #
262
+ @grid = default_grid
263
+ end
264
+
265
+ # ========================================================================= #
266
+ # === use_close_image
267
+ # ========================================================================= #
268
+ def use_close_image
269
+ change_location_of_the_image(:close_image)
270
+ end
271
+
272
+ # ========================================================================= #
273
+ # === change_location_of_the_image
274
+ #
275
+ # With this you can manipulate @location_of_the_image
276
+ # ========================================================================= #
277
+ def change_location_of_the_image(
278
+ this_location = @location_of_the_image
279
+ )
280
+ img = '/home/x/data/images/'
281
+ case this_location.to_s
282
+ when 'rand','r'
283
+ # cd $RUBY_GTK/GAM/MINESWEEPER/images/symbols/
284
+ img_base = ENV['RUBY_GTK'].to_s+'/games/MINESWEEPER/images/symbols/'
285
+ case rand(7)
286
+ when 0 then set_location_of_the_image(img_base+'bang.png')
287
+ when 1 then set_location_of_the_image(img_base+'flag.png')
288
+ when 2 then set_location_of_the_image(img_base+'flag-question.png')
289
+ when 3 then set_location_of_the_image(img_base+'mine.png')
290
+ when 4 then set_location_of_the_image(
291
+ '/home/x/programming/ruby/src/cyberweb/lib/cyberweb/images/standard_images/TELEFON.png'
292
+ )
293
+ when 5 then change_location_of_the_image('bopen')
294
+ when 6 then change_location_of_the_image('bclose')
295
+ end
296
+ # ======================================================================= #
297
+ # === shield
298
+ #
299
+ # shield icon
300
+ # ======================================================================= #
301
+ when 'shield',
302
+ 's'
303
+ set_location_of_the_image(project_base_directory?+'images/misc/small_shield.png')
304
+ # ======================================================================= #
305
+ # === close_image
306
+ # ======================================================================= #
307
+ when /^-?-?close(_|-)?image$/,
308
+ /^-?-?close(_|-)?picture$/
309
+ set_location_of_the_image(project_base_directory?+'images/icons/close_image.png')
310
+ # ======================================================================= #
311
+ # === alert
312
+ #
313
+ # Ausrufungszeichen
314
+ # ======================================================================= #
315
+ when 'alert',
316
+ 'ausrufungszeichen'
317
+ set_location_of_the_image(img+'/STD/AUSRUFUNGSZEICHEN.png')
318
+ # ======================================================================= #
319
+ # === book_open
320
+ # ======================================================================= #
321
+ when /book_open/,
322
+ /bopen/
323
+ set_location_of_the_image(img+'/STD/BOOK_OPENED.png')
324
+ # ======================================================================= #
325
+ # === book_close
326
+ # ======================================================================= #
327
+ when /book_close/,
328
+ /bclose/
329
+ set_location_of_the_image(img+'/STD/BOOK_CLOSED.png')
330
+ end
331
+ end
332
+
333
+ # ========================================================================= #
334
+ # === connect_skeleton (connect tag)
335
+ # ========================================================================= #
336
+ def connect_skeleton
337
+ abort_on_exception
338
+ # ======================================================================= #
339
+ # The placement can be towards the left, or towards the right. The
340
+ # following code will properly distinguish between these two
341
+ # possibilities.
342
+ # ======================================================================= #
343
+ case placement?
344
+ # ======================================================================= #
345
+ # === :left
346
+ # ======================================================================= #
347
+ when :left
348
+ @grid.left(return_the_event_box)
349
+ @grid.right(modify_label(@label_title, @text_colour))
350
+ # ======================================================================= #
351
+ # === :right
352
+ # ======================================================================= #
353
+ when :right
354
+ @grid.left(modify_label(@label_title, @text_colour))
355
+ @grid.right(return_the_event_box)
356
+ else
357
+ e 'Unknown placement.'
358
+ end
359
+ minimal(@grid)
360
+ end
361
+
362
+ # ========================================================================= #
363
+ # === set_index
364
+ # ========================================================================= #
365
+ def set_index(index = 0)
366
+ @index = index
367
+ end
368
+
369
+ # ========================================================================= #
370
+ # === index?
371
+ # ========================================================================= #
372
+ def index?
373
+ @index
374
+ end
375
+
376
+ # ========================================================================= #
377
+ # === return_the_event_box
378
+ #
379
+ # When the user clicks on the event box containing our image (which may
380
+ # be a close button image, aka a 'x') then we will quit the part there.
381
+ # ========================================================================= #
382
+ def return_the_event_box
383
+ hbox = create_hbox
384
+ hbox.css_class('BG_'+@background_colour.to_s)
385
+ hbox.minimal(@image, 1)
386
+ event_box = create_event_box(hbox)
387
+ event_box.signal_connect(:event) {|widget, event|
388
+ case event.to_s # This is <Gdk::EventType enter-notify>.
389
+ when /EventCrossing/
390
+ case event.name?
391
+ when 'GDK_ENTER_NOTIFY' # on-enter event.
392
+ hbox.remove_css_class('BG_'+@background_colour.to_s)
393
+ hbox.css_class('BG_lightskyblue')
394
+ when 'GDK_LEAVE_NOTIFY' # on-leave event.
395
+ hbox.remove_css_class('BG_lightskyblue')
396
+ hbox.css_class('BG_'+@background_colour.to_s)
397
+ end
398
+ end
399
+ }
400
+ event_box.on_clicked {
401
+ do_perform_either_the_destroy_the_widget_action_or_call_a_parent_method
402
+ }
403
+ return event_box
404
+ end
405
+
406
+ # ========================================================================= #
407
+ # === do_perform_either_the_destroy_the_widget_action_or_call_a_parent_method
408
+ # ========================================================================= #
409
+ def do_perform_either_the_destroy_the_widget_action_or_call_a_parent_method
410
+ if parent_widget?
411
+ parent_widget?.do_action_associated_with_the_icon_pressed(self)
412
+ else
413
+ destroy # Destroy the widget here.
414
+ end
415
+ end
416
+
417
+ # ========================================================================= #
418
+ # === create_skeleton (create tag, skeleton tag)
419
+ # ========================================================================= #
420
+ def create_skeleton
421
+ create_the_image
422
+ create_the_grid
423
+ end
424
+
425
+ # ========================================================================= #
426
+ # === run (run tag)
427
+ # ========================================================================= #
428
+ def run
429
+ super()
430
+ change_location_of_the_image
431
+ update_icon
432
+ self.can_focus = false
433
+ show_all
434
+ end
435
+
436
+ # ========================================================================= #
437
+ # === Gtk::NotebookTabWithIcon.widget
438
+ #
439
+ # This method will return a new instance of Gtk::NotebookTabWithIcon.
440
+ # ========================================================================= #
441
+ def self.widget(
442
+ use_this_title = '',
443
+ use_this_icon = :tabble,
444
+ &block
445
+ )
446
+ if use_this_title.is_a? Array
447
+ use_this_title = use_this_title.join(' ')
448
+ end
449
+ case use_this_title
450
+ # ======================================================================= #
451
+ # === :default
452
+ # ======================================================================= #
453
+ when :default
454
+ use_this_title = 'Here is the original label.'
455
+ end
456
+ _ = ::Gtk::NotebookTabWithIcon.new(
457
+ use_this_icon,
458
+ use_this_title,
459
+ &block
460
+ )
461
+ _.make_bold
462
+ return _
463
+ end
18
464
 
19
465
  # ========================================================================= #
20
466
  # === Gtk::NotebookTabWithIcon.run
21
467
  # ========================================================================= #
22
- def self.run
23
- ::Gtk::NotebookTabWithIconModule.run
468
+ def self.run(
469
+ i = ARGV,
470
+ &block
471
+ )
472
+ require 'gtk_paradise/app/app.rb'
473
+ _ = widget(i, :tabble, &block)
474
+ r = ::Gtk.run
475
+ r << _
476
+ r.automatic_size_then_automatic_title
477
+ r.enable_quick_exit
478
+ r.top_left_then_run
24
479
  end
25
480
 
26
481
  end; end
27
482
 
28
483
  if __FILE__ == $PROGRAM_NAME
29
- Gtk::NotebookTabWithIcon.run
484
+ # ========================================================================= #
485
+ # We can pass in a different colour, such as :royalblue.
486
+ # ========================================================================= #
487
+ Gtk::NotebookTabWithIcon.run(:default) {{
488
+ text_colour: :royalblue, # @text_colour = text_colour
489
+ use_close_image: true,
490
+ placement: :right
491
+ }}
30
492
  end
@@ -0,0 +1,180 @@
1
+ #!/usr/bin/ruby -w
2
+ # Encoding: UTF-8
3
+ # frozen_string_literal: true
4
+ # =========================================================================== #
5
+ # === Gtk::NotebookWithStorageFunctionality
6
+ #
7
+ # This notebook can be used if you need a save-into-file functionality.
8
+ #
9
+ # Eventually this widget should be made very flexible.
10
+ # =========================================================================== #
11
+ # require 'gtk_paradise/widgets/gtk3/notebook_with_storage_functionality/notebook_with_storage_functionality.rb'
12
+ # Gtk::NotebookWithStorageFunctionality.run
13
+ # =========================================================================== #
14
+ require 'gtk_paradise/require_gtk3'
15
+
16
+ module Gtk
17
+
18
+ class NotebookWithStorageFunctionality < ::Gtk::BaseModuleBox # === Gtk::NotebookWithStorageFunctionality
19
+
20
+ require 'yaml'
21
+
22
+ # ========================================================================= #
23
+ # === TITLE
24
+ # ========================================================================= #
25
+ TITLE = 'Notebook with storage functionality'
26
+
27
+ # ========================================================================= #
28
+ # === WIDTH
29
+ # ========================================================================= #
30
+ WIDTH = '95% or minimum 1480px'
31
+
32
+ # ========================================================================= #
33
+ # === HEIGHT
34
+ # ========================================================================= #
35
+ HEIGHT = '55% or minimum 600px'
36
+
37
+ # ========================================================================= #
38
+ # === USE_THIS_FONT
39
+ # ========================================================================= #
40
+ USE_THIS_FONT = :hack_22
41
+
42
+ # ========================================================================= #
43
+ # === SMALLER_FONT
44
+ # ========================================================================= #
45
+ SMALLER_FONT = :hack_18
46
+
47
+ # ========================================================================= #
48
+ # === initialize
49
+ # ========================================================================= #
50
+ def initialize(
51
+ commandline_arguments = ARGV,
52
+ run_already = true
53
+ )
54
+ super(:vertical)
55
+ reset
56
+ horizontal_center
57
+ set_commandline_arguments(
58
+ commandline_arguments
59
+ )
60
+ run if run_already
61
+ end
62
+
63
+ # ========================================================================= #
64
+ # === reset (reset tag)
65
+ # ========================================================================= #
66
+ def reset
67
+ reset_the_internal_variables
68
+ infer_the_namespace
69
+ # ======================================================================= #
70
+ # === @configuration
71
+ # ======================================================================= #
72
+ @configuration = [true, __dir__, namespace?]
73
+ # ======================================================================= #
74
+ # === Set the title, width, height and the font in use.
75
+ # ======================================================================= #
76
+ title_width_height_font(TITLE, WIDTH, HEIGHT, USE_THIS_FONT)
77
+ handle_CSS_rules
78
+ infer_the_size_automatically
79
+ end
80
+
81
+ # ========================================================================= #
82
+ # === handle_CSS_rules (CSS tag)
83
+ # ========================================================================= #
84
+ def handle_CSS_rules
85
+ use_gtk_paradise_project_css_file
86
+ end
87
+
88
+ # ========================================================================= #
89
+ # === smaller_font?
90
+ # ========================================================================= #
91
+ def smaller_font?
92
+ SMALLER_FONT
93
+ end
94
+
95
+ # ========================================================================= #
96
+ # === padding?
97
+ # ========================================================================= #
98
+ def padding?
99
+ 0
100
+ end
101
+
102
+ # ========================================================================= #
103
+ # === border_size?
104
+ # ========================================================================= #
105
+ def border_size?
106
+ 0
107
+ end
108
+
109
+ # ========================================================================= #
110
+ # === create_skeleton (create tag, skeleton tag)
111
+ # ========================================================================= #
112
+ def create_skeleton
113
+ @text_view = create_text_view
114
+ maximal(@text_view)
115
+ button_store_the_content = create_button('_Store the content')
116
+ button_store_the_content.hint = 'Click this button to '\
117
+ 'store the content into a file.'
118
+ button_store_the_content.on_clicked {
119
+ do_store_the_content
120
+ }
121
+ button_store_the_content.clear_background
122
+ button_store_the_content.on_hover(:lightblue)
123
+ button_store_the_content.bblack2
124
+ button_store_the_content.pad4px
125
+ button_store_the_content.css_class('margin2px')
126
+ box1 = create_hbox
127
+ box1.minimal(button_store_the_content, 2)
128
+ box1.hcenter
129
+ minimal(box1)
130
+ end
131
+
132
+ # ========================================================================= #
133
+ # === do_store_the_content
134
+ # ========================================================================= #
135
+ def do_store_the_content
136
+ _ = @text_view.text?
137
+ into = '/home/x/Temp/notebook_content.md'
138
+ write_what_into(_, into)
139
+ end
140
+
141
+ # ========================================================================= #
142
+ # === connect_skeleton (connect tag)
143
+ # ========================================================================= #
144
+ def connect_skeleton
145
+ abort_on_exception
146
+ end
147
+
148
+ # ========================================================================= #
149
+ # === run (run tag)
150
+ # ========================================================================= #
151
+ def run
152
+ super()
153
+ end
154
+
155
+ # ========================================================================= #
156
+ # === Gtk::NotebookWithStorageFunctionality.run
157
+ # ========================================================================= #
158
+ def self.run(
159
+ i = ARGV
160
+ )
161
+ require 'gtk_paradise/app/app.rb'
162
+ _ = ::Gtk::NotebookWithStorageFunctionality.new(i)
163
+ r = ::Gtk.run
164
+ r << _
165
+ # ======================================================================= #
166
+ # Add two convenience keybindings next:
167
+ # ======================================================================= #
168
+ r.alt_key(1, 'focus_entry(1)') # alt+1
169
+ r.alt_key(2, 'focus_entry(2)') # alt+2
170
+ r.alt_key(3, 'focus_entry(3)') # alt+3
171
+ r.automatic_size_then_automatic_title
172
+ r.enable_quick_exit
173
+ r.top_left_then_run
174
+ end
175
+
176
+ end; end
177
+
178
+ if __FILE__ == $PROGRAM_NAME
179
+ Gtk::NotebookWithStorageFunctionality.run
180
+ end