### Example: Scaffold Desktopify App for Brighton Resort Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_COMMAND.md Demonstrates scaffolding a desktop application named 'snowboard_utah' for the website 'https://www.brightonresort.com'. The command generates application files and packages them, producing detailed console output indicating file creation and project setup. ```Shell glimmer scaffold:desktopify[snowboard_utah,https://www.brightonresort.com] ``` -------------------------------- ### Glimmer DSL for SWT: Hello, Table! GUI Example Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/README.md Demonstrates building a 'Hello, Table!' GUI application using Glimmer DSL for SWT. This example showcases creating a window with a grid layout, displaying text, images, labels, combo boxes, and a complex editable table. It highlights data binding for table items and selection, custom column editors (date, time, combo), sorting, and context menus, along with button interactions. ```Ruby shell { grid_layout text 'Hello, Table!' background_image File.expand_path('hello_table/baseball_park.png', __dir__) image File.expand_path('hello_table/baseball_park.png', __dir__) label { layout_data :center, :center, true, false text 'BASEBALL PLAYOFF SCHEDULE' background :transparent if OS.windows? foreground rgb(94, 107, 103) font name: 'Optima', height: 38, style: :bold } combo(:read_only) { layout_data :center, :center, true, false selection <=> [BaseballGame, :playoff_type] font height: 14 } table(:editable) { |table_proxy| layout_data :fill, :fill, true, true table_column { text 'Game Date' width 150 sort_property :date # ensure sorting by real date value (not `game_date` string specified in items below) editor :date_drop_down, property: :date_time } table_column { text 'Game Time' width 150 sort_property :time # ensure sorting by real time value (not `game_time` string specified in items below) editor :time, property: :date_time } table_column { text 'Ballpark' width 180 editor :none } table_column { text 'Home Team' width 150 editor :combo, :read_only # read_only is simply an SWT style passed to combo widget } table_column { text 'Away Team' width 150 editor :combo, :read_only # read_only is simply an SWT style passed to combo widget } table_column { text 'Promotion' width 150 # default text editor is used here } # Data-bind table items (rows) to a model collection property, specifying column properties ordering per nested model items <=> [BaseballGame, :schedule, column_properties: [:game_date, :game_time, :ballpark, :home_team, :away_team, :promotion]] # Data-bind table selection selection <=> [BaseballGame, :selected_game] # Default initial sort property sort_property :date # Sort by these additional properties after handling sort by the column the user clicked additional_sort_properties :date, :time, :home_team, :away_team, :ballpark, :promotion menu { menu_item { text 'Book' on_widget_selected { book_selected_game } } } } button { text 'Book Selected Game' layout_data :center, :center, true, false font height: 14 enabled <= [BaseballGame, :selected_game] on_widget_selected do book_selected_game end } } ``` -------------------------------- ### Install Dependencies and Run Initial Tests Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/CONTRIBUTING.md Installs project dependencies using Bundler and runs initial RSpec tests. These commands should be executed within the `glimmer-dsl-swt` project directory after setting up the environment. ```Shell gem install bundler bundle rake ``` -------------------------------- ### Install Glimmer DSL for SWT Gem Directly Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/README.md This command installs the latest stable version of the `glimmer-dsl-swt` gem using `jgem`, JRuby's package manager. This is the recommended method for learning basics or using scaffolding. Note that `jgem` is JRuby's version of the `gem` command, and RVM allows running `gem install` directly as an alias. ```Ruby jgem install glimmer-dsl-swt ``` -------------------------------- ### Glimmer DSL for SWT: Tetris Game Example Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/README.md Illustrates building a Tetris game using Glimmer DSL for SWT. This example demonstrates setting up a shell with a grid layout, custom minimum size, and integrating custom components like a menu bar, playfield, and score lane, showcasing advanced GUI application development. ```Ruby shell(:no_resize) { grid_layout { num_columns 2 make_columns_equal_width false margin_width 0 margin_height 0 horizontal_spacing 0 } text 'Glimmer Tetris' minimum_size 475, 500 image tetris_icon tetris_menu_bar(game: game) playfield(game_playfield: game.playfield, playfield_width: playfield_width, playfield_height: playfield_height, block_size: BLOCK_SIZE) score_lane(game: game, block_size: BLOCK_SIZE) { layout_data(:fill, :fill, true, true) } } ``` -------------------------------- ### Install Glimmer DSL SWT Dependencies with JRuby Bundler Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/README.md Explains how to run `bundle install` using JRuby to resolve and install the gems specified in the `Gemfile`, including `glimmer-dsl-swt`. This command should be executed after updating the `Gemfile`. ```Shell jruby -S bundle install ``` -------------------------------- ### List Available Glimmer Samples Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_COMMAND.md Demonstrates how to list all available Glimmer samples by executing the `glimmer samples` command. This command launches the Glimmer Meta-Sample application, providing an interactive way to explore different Glimmer examples. ```Ruby glimmer samples ``` -------------------------------- ### Generate MSI Package for Windows Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_PACKAGING_AND_DISTRIBUTION.md Generates a Microsoft Installer (MSI) setup file specifically for Windows. This requires the Wix Toolset to be installed and its bin directory added to the system PATH for successful execution. ```Shell glimmer package[msi] ``` -------------------------------- ### Example Output for Glimmer Application Scaffolding Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_COMMAND.md Illustrates the console output when scaffolding a Glimmer application named 'greeter'. The output details the creation of numerous files and directories, including `.gitignore`, `Rakefile`, `Gemfile`, application source files, and platform-specific packaging assets. ```Shell $ glimmer scaffold[greeter] create .gitignore create Rakefile create Gemfile create LICENSE.txt create README.markdown create .document create lib create lib/snowboard_utah.rb create .rspec Juwelier has prepared your gem in ./snowboard_utah Created greeter/.gitignore Created greeter/.ruby-version Created greeter/.ruby-gemset Created greeter/VERSION Created greeter/LICENSE.txt Created greeter/Gemfile Created greeter/Rakefile Created greeter/app/greeter.rb Created greeter/app/greeter/view/app_view.rb Created greeter/package/windows/Snowboard Utah.ico Created greeter/package/macosx/Snowboard Utah.icns Created greeter/package/linux/Snowboard Utah.png Created greeter/app/greeter/launch.rb Created greeter/bin/greeter ... ``` -------------------------------- ### Run Glimmer Samples Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_COMMAND.md Launches the Glimmer Meta-Sample, which serves as a collection of all Glimmer samples. This command provides an easy way to explore various Glimmer functionalities and examples. ```Shell glimmer samples ``` -------------------------------- ### Run Glimmer DSL SWT Samples Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/README.md To explore Glimmer DSL for SWT applications, you can run the provided samples directly from the installed gem. This command launches a sample browser, showcasing various Glimmer features and usage patterns. ```Ruby glimmer samples ``` -------------------------------- ### Install Specific Version of Glimmer DSL for SWT Gem Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/README.md Use this command to install a particular version of the `glimmer-dsl-swt` gem. This is useful for compatibility or if a newer version has issues, allowing you to specify the exact version number. ```Ruby jgem install glimmer-dsl-swt -v 4.30.1.1 ``` -------------------------------- ### Start Glimmer Interactive Ruby Shell (girb) Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/CONTRIBUTING.md Launches the local `bin/girb` interactive Ruby shell. This provides an environment to experiment with Glimmer DSL for SWT syntax and features interactively during development. ```Ruby bin/girb ``` -------------------------------- ### Build Glimmer DSL for SWT Gem Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/CONTRIBUTING.md Builds the `glimmer-dsl-swt` Ruby gem, compiling and packaging it into the `pkg` directory. This is necessary for distribution or local installation. ```Ruby rake build ``` -------------------------------- ### Package Glimmer App with Default Type Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_PACKAGING_AND_DISTRIBUTION.md Executes the `glimmer package` command without specifying a type. This generates the default native executable for the current platform, such as an `app-image`. It also provides feedback on any missing prerequisite setup tools. ```Shell glimmer package ``` -------------------------------- ### Run Girb Command for Glimmer DSL for SWT Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_GIRB.md Execute the `girb` command after installing `glimmer-dsl-swt` to launch an interactive Ruby shell with SWT preloaded and the Glimmer library included, enabling quick Glimmer coding and testing. ```Shell girb ``` -------------------------------- ### Run Glimmer Samples from Local Project Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_COMMAND.md Executes the Glimmer samples directly from a locally cloned project directory. This command is used when the Glimmer gem is not installed globally, and the user wants to run samples via the project's executable script. ```Shell bin/glimmer samples ``` -------------------------------- ### Basic Calculator with Data-Binding and TDD (Ruby) Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This external sample, Glimmer Calculator, is a basic calculator application that demonstrates data-binding and Test-Driven Development (TDD) principles. It follows the Model-View-Presenter (MVP) architectural pattern, providing a clear example of building a robust and testable GUI application. ```Ruby https://github.com/AndyObtiva/glimmer-cs-calculator ``` -------------------------------- ### Generate DMG Package for Mac Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_PACKAGING_AND_DISTRIBUTION.md Generates a Disk Image (DMG) file for macOS applications. This command creates a standard macOS installer package, ready for distribution on Apple systems. ```Shell glimmer package[dmg] ``` -------------------------------- ### Build a Weather App with Net::HTTP and JSON Data Binding (Ruby) Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This sample implements a Weather application that fetches data from openweathermap.org using Ruby's built-in 'net/http' library. It provides a practical example of parsing hierarchical JSON data (hashes and arrays) and converting it into data-bindable model object attributes for seamless synchronization with the Glimmer GUI. ```Ruby samples/elaborate/weather.rb ``` -------------------------------- ### Declare Glimmer GUI Widget with Style Arguments Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/README.md Widgets in Glimmer GUI DSL can optionally receive symbol-style arguments within parentheses to specify their behavior. This example shows how to declare a `table` widget with multi-line selection capability. ```Ruby table(:multi) ``` -------------------------------- ### Scaffold Glimmer Desktopify App Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_COMMAND.md Generates a Glimmer application that wraps a specified website into a desktop application using the Browser Widget. It packages the app for various operating systems (Mac, Windows, Linux) and remembers cookies. Requires a JRuby environment with Glimmer gem installed. ```Shell glimmer scaffold:desktopify[app_name,website] ``` -------------------------------- ### List Glimmer Custom Widget Gems Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_COMMAND.md This command lists available Glimmer Custom Widget Gems, prefixed with 'glimmer-cw-'. It queries rubygems.org for community-created gems. Examples show how to filter by a query string like 'video' or list all available custom widgets. ```Shell glimmer list:gems:customwidget[query] ``` ```Shell glimmer list:gems:cw[query] ``` ```Shell glimmer list:gems:cw[video] ``` ```Text Glimmer Custom Widget Gems matching [video] at rubygems.org: Name Gem Version Author Description Video glimmer-cw-video 1.0.0 Andy Maleh Glimmer Custom Widget - Video ``` ```Shell glimmer list:gems:cw ``` ```Text Glimmer Custom Widget Gems at rubygems.org: Name Gem Version Author Description Browser (Chromium) glimmer-cw-browser-chromium 1.0.0 Andy Maleh Chromium Browser - Glimmer Custom Widget Cdatetime (Nebula) glimmer-cw-cdatetime-nebula 1.5.0.0.1 Andy Maleh Nebula CDateTime Widget - Glimmer Custom Widget Video glimmer-cw-video 1.0.0 Andy Maleh Glimmer Custom Widget - Video ``` -------------------------------- ### Glimmer DSL SWT Funnotator UI Grid Example Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/TODO.md This Ruby Glimmer DSL for SWT snippet demonstrates the creation of a `shell` with a `fill_layout` and a `composite` using a `grid_layout`. It dynamically generates a 5x10 grid of disabled `button` widgets, each bound to a character property of a `Struct` for a 'Funnotator' application. It showcases basic UI layout and data binding capabilities within the Glimmer framework. ```Ruby shell do fill_layout text "Funnotator" minimum_size 1000, 700 composite do grid_layout 10, true char = Struct.new :char, :annotation code = 5.times.map do |i| 10.times.map do |j| char.new("Z").tap do |char| button do enabled false font height: 30, style: :bold text bind(char, :char) layout_data do width_hint 90 height_hint 80 end end end end end end end.open ``` -------------------------------- ### Render Mandelbrot Fractal with Multi-threaded Canvas Graphics (Ruby) Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This sample demonstrates how to render canvas graphics with multi-threaded processing, leveraging all CPU cores for background image processing. It renders the Mandelbrot Fractal, enabling zooming and panning, and starts quickly due to multi-core optimization. Users can adjust core usage for more responsive interaction. ```Ruby samples/elaborate/mandelbrot_fractal.rb ``` -------------------------------- ### Create a Metronome with Canvas Shape DSL and Java Sound (Ruby) Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This sample demonstrates a Metronome application that accepts beat count and BPM rate, providing an audible tick at each beat with an uptick at the rhythm interval start. It leverages the Canvas Shape DSL, data-binding, and the Java Sound library, combining standard widget layouts with precise canvas shape placement. ```Ruby samples/elaborate/metronome.rb ``` -------------------------------- ### Add Event Listener to Glimmer GUI Widget Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/README.md Glimmer GUI DSL supports event listeners following the Observer Design Pattern, prefixed with `on_`. Listeners require a `do; end` block to distinguish logic from view syntax. This example demonstrates adding an `on_widget_selected` listener to a button, which opens a message box upon selection. ```Ruby button { text 'Click' on_widget_selected do message_box { text 'Clicked' message 'Thank you for clicking!' }.open end } ``` -------------------------------- ### Hello, Shell! - Glimmer DSL for SWT Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This sample demonstrates the various shells (windows) available in SWT, showcasing different window styles and behaviors. ```Ruby samples/hello/hello_shell.rb ``` -------------------------------- ### Launch Glimmer Meta-Sample for Exploring Samples Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This command launches the Glimmer Meta-Sample, a GUI application that serves as a sample browser. It allows users to explore, run, and even edit the code of various Glimmer applications before launching them, facilitating interactive learning. ```Shell glimmer samples ``` -------------------------------- ### Hello, Tab! - Glimmer DSL for SWT Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This sample demonstrates the basic usage of tab widgets in Glimmer DSL for SWT, showcasing how to organize content into multiple sections. ```Ruby samples/hello/hello_tab.rb ``` -------------------------------- ### Create a Basic Hello, World! Glimmer GUI Application Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/README.md This snippet demonstrates how to create a simple 'Hello, World!' graphical user interface application using Glimmer DSL for SWT. It initializes a shell window with a title and adds a label displaying the 'Hello, World!' text. The application opens upon execution, showcasing the basic structure of a Glimmer GUI program. ```ruby include Glimmer shell { text "Glimmer" label { text "Hello, World!" } }.open ``` -------------------------------- ### Glimmer CLI Command Reference and Tasks Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/README.md Comprehensive documentation for the `glimmer` command-line interface, detailing its general usage, available options, and a complete list of tasks for application management, including scaffolding, running, packaging, and listing Glimmer components and gems. ```APIDOC Glimmer (JRuby Desktop Development GUI Framework) - JRuby Gem: glimmer-dsl-swt v4.30.1.1 Usage: glimmer [--bundler] [--pd] [--quiet] [--debug] [--log-level=VALUE] [[ENV_VAR=VALUE]...] [[-jruby-option]...] (application.rb or task[task_args]) [[application2.rb]...] Runs Glimmer applications and tasks. When applications are specified, they are run using JRuby, automatically preloading the glimmer Ruby gem and SWT jar dependency. Optionally, extra Glimmer options, JRuby options, and/or environment variables may be passed in. Glimmer options: - "--bundler=GROUP" : Activates gems in Bundler default group in Gemfile - "--pd=BOOLEAN" : Requires puts_debuggerer to enable pd method - "--quiet=BOOLEAN" : Does not announce file path of Glimmer application being launched - "--debug" : Displays extra debugging information, passes "--debug" to JRuby, and enables debug logging - "--log-level=VALUE" : Sets Glimmer's Ruby logger level ("ERROR" / "WARN" / "INFO" / "DEBUG"; default is none) Tasks are run via rake. Some tasks take arguments in square brackets. Available tasks are below (if you do not see any, please add `require 'glimmer/rake_task'` to Rakefile and rerun or run rake -T): Select a Glimmer task to run: (Press ↑/↓ arrow to move, Enter to select and letters to filter) glimmer list:gems:customshape[query] # List Glimmer custom shape gems available at rubygems.org (query is optional) [alt: list:gems:cp] ‣ glimmer list:gems:customshell[query] # List Glimmer custom shell gems available at rubygems.org (query is optional) [alt: list:gems:cs] glimmer list:gems:customwidget[query] # List Glimmer custom widget gems available at rubygems.org (query is optional) [alt: list:gems:cw] glimmer list:gems:dsl[query] # List Glimmer DSL gems available at rubygems.org (query is optional) glimmer package[type] # Package app for distribution (generating config, jar, and native files) (type is optional) glimmer package:clean # Clean by removing "dist" and "packages" directories glimmer package:config # Generate JAR config file glimmer package:gem # Generate gem under pkg directory glimmer package:gemspec # Generate gemspec glimmer package:jar # Generate JAR file glimmer package:lock_jars # Lock JARs glimmer package:native[type] # Generate Native files glimmer run[app_path] # Runs Glimmer app or custom shell gem in the current directory, unless app_path is specified, then runs it instead (app_path is optional) glimmer samples # Brings up the Glimmer Meta-Sample app to allow browsing, running, and viewing code of Glimmer samples glimmer scaffold[app_name] # Scaffold Glimmer application directory structure to build a new app glimmer scaffold:customshape[name,namespace] # Scaffold Glimmer::UI::CustomShape subclass (part of a view) under app/views (namespace is optional) [alt: scaffold:cp] glimmer scaffold:customshell[name,namespace] # Scaffold Glimmer::UI::CustomShell subclass (full window view) under app/views (namespace is optional) [alt: scaffold:cs] glimmer scaffold:customwidget[name,namespace] # Scaffold Glimmer::UI::CustomWidget subclass (part of a view) under app/views (namespace is optional) [alt: scaffold:cw] glimmer scaffold:desktopify[app_name,website] # Desktopify a web app glimmer scaffold:gem:customshape[name,namespace] # Scaffold Glimmer::UI::CustomShape subclass (part of a view) under its own Ruby gem project (namespace is required) [alt: scaffold:gem:cp] glimmer scaffold:gem:customshell[name,namespace] # Scaffold Glimmer::UI::CustomShell subclass (full window view) under its own Ruby gem + app project (namespace is required) [alt: scaffold:ge... glimmer scaffold:gem:customwidget[name,namespace] # Scaffold Glimmer::UI::CustomWidget subclass (part of a view) under its own Ruby gem project (namespace is required) [alt: scaffold:gem:cw] ``` -------------------------------- ### Hello, Browser! - Glimmer DSL for SWT Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This sample demonstrates the usage of the `browser` widget in Glimmer DSL for SWT, allowing embedding and interaction with web content directly within a desktop application. ```Ruby samples/hello/hello_browser.rb ``` -------------------------------- ### Hello, Combo! - Glimmer DSL for SWT Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This sample demonstrates basic combo data-binding in Glimmer DSL for SWT, illustrating how to connect UI dropdowns to application data. ```Ruby samples/hello/hello_combo.rb ``` -------------------------------- ### Run Glimmer DSL for SWT Sample Application Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/CONTRIBUTING.md Executes a specified Glimmer DSL for SWT sample application using the local `bin/glimmer` command. This allows developers to test and observe sample functionality in a development environment. ```Ruby bin/glimmer samples/hello_world.rb ``` -------------------------------- ### Defining the Glimmer Application Launch Script Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_PACKAGING_AND_DISTRIBUTION.md Details the structure and content of the required Ruby script, typically located in the `bin` directory, that serves as the entry point for launching the Glimmer application. This script ensures the main application file is loaded correctly. ```Ruby require_relative '../app/my_application.rb' ``` -------------------------------- ### Run Specific Glimmer Sample File Directly Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This command demonstrates how to execute a particular Glimmer sample file directly from the project's `bin` directory. It serves as an alternative method for running samples, especially if the Meta-Sample is not used or encounters issues, requiring the project to be cloned and dependencies bundled. ```Ruby bin/glimmer samples/hello/hello_canvas_transform.rb ``` -------------------------------- ### Basic Glimmer Command Invocation Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/README.md Demonstrates the simplest way to invoke the `glimmer` command, which typically displays its usage information and available options. ```Shell glimmer ``` -------------------------------- ### Implement Parking Spot Booking with Custom Shapes and Transforms (Ruby) Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This sample demonstrates the use of method-based custom shapes and graphical transforms, specifically rotation, to create an interactive parking spot booking interface. It simulates booking a parking spot at a building's entrance, showcasing advanced UI rendering techniques. ```Ruby samples/elaborate/parking.rb ``` -------------------------------- ### Hello, Toggle! - Glimmer DSL for SWT Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This sample demonstrates the use of the `toggle` button (aka `button(:toggle)`) in Glimmer DSL for SWT, illustrating its behavior for managing boolean states and visual feedback. ```Ruby samples/hello/hello_toggle.rb ``` -------------------------------- ### Hello, C Combo! - Glimmer DSL for SWT Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This sample demonstrates the custom combo variation on combo, which allows the adjustment of the combo height based on font height or layout data. ```Ruby samples/hello/hello_c_combo.rb ``` -------------------------------- ### Glimmer CLI Command-Line Usage and Tasks Reference Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_COMMAND.md Documents the full command-line interface for the `glimmer` tool, including general usage syntax, available Glimmer-specific options, and how to run applications and tasks. It also lists various `rake` tasks for development workflows, such as listing gems, packaging applications, and scaffolding new projects. ```APIDOC Glimmer (JRuby Desktop Development GUI Framework) - JRuby Gem: glimmer-dsl-swt v4.18.7.4 Usage: glimmer [--bundler] [--pd] [--quiet] [--debug] [--log-level=VALUE] [[ENV_VAR=VALUE]...] [[-jruby-option]...] (application.rb or task[task_args]) [[application2.rb]...] Runs Glimmer applications and tasks. When applications are specified, they are run using JRuby, automatically preloading the glimmer Ruby gem and SWT jar dependency. Optionally, extra Glimmer options, JRuby options, and/or environment variables may be passed in. Glimmer options: - "--bundler=GROUP" : Activates gems in Bundler default group in Gemfile - "--pd=BOOLEAN" : Requires puts_debuggerer to enable pd method - "--quiet=BOOLEAN" : Does not announce file path of Glimmer application being launched - "--debug" : Displays extra debugging information, passes "--debug" to JRuby, and enables debug logging - "--log-level=VALUE" : Sets Glimmer's Ruby logger level ("ERROR" / "WARN" / "INFO" / "DEBUG"; default is none) Tasks are run via rake. Some tasks take arguments in square brackets. Available tasks are below (if you do not see any, please add `require 'glimmer/rake_task'` to Rakefile and rerun or run rake -T): Select a Glimmer task to run: (Press ↑/↓ arrow to move, Enter to select and letters to filter) glimmer list:gems:customshape[query] # List Glimmer custom shape gems available at rubygems.org (query is optional) [alt: list:gems:cp] ‣ glimmer list:gems:customshell[query] # List Glimmer custom shell gems available at rubygems.org (query is optional) [alt: list:gems:cs] glimmer list:gems:customwidget[query] # List Glimmer custom widget gems available at rubygems.org (query is optional) [alt: list:gems:cw] glimmer list:gems:dsl[query] # List Glimmer DSL gems available at rubygems.org (query is optional) glimmer package[type] # Package app for distribution (generating config, jar, and native files) (type is optional) glimmer package:clean # Clean by removing "dist" and "packages" directories glimmer package:config # Generate JAR config file glimmer package:gem # Generate gem under pkg directory glimmer package:gemspec # Generate gemspec glimmer package:jar # Generate JAR file glimmer package:lock_jars # Lock JARs glimmer package:native[type] # Generate Native files glimmer run[app_path] # Runs Glimmer app or custom shell gem in the current directory, unless app_path is specified, then runs it instead (app_path is optional) glimmer samples # Brings up the Glimmer Meta-Sample app to allow browsing, running, and viewing code of Glimmer samples glimmer scaffold[app_name] # Scaffold Glimmer application directory structure to build a new app glimmer scaffold:customshape[name,namespace] # Scaffold Glimmer::UI::CustomShape subclass (part of a view) under app/views (namespace is optional) [alt: scaffold:cp] glimmer scaffold:customshell[name,namespace] # Scaffold Glimmer::UI::CustomShell subclass (full window view) under app/views (namespace is optional) [alt: scaffold:cs] glimmer scaffold:customwidget[name,namespace] # Scaffold Glimmer::UI::CustomWidget subclass (part of a view) under app/views (namespace is optional) [alt: scaffold:cw] glimmer scaffold:desktopify[app_name,website] # Desktopify a web app glimmer scaffold:gem:customshape[name,namespace] # Scaffold Glimmer::UI::CustomShape subclass (part of a view) under its own Ruby gem project (namespace is required) [alt: scaffold:gem:cp] glimmer scaffold:gem:customshell[name,namespace] # Scaffold Glimmer::UI::CustomShell subclass (full window view) under its own Ruby gem + app project (namespace is required) [alt: scaffold:ge... glimmer scaffold:gem:customwidget[name,namespace] # Scaffold Glimmer::UI::CustomWidget subclass (part of a view) under its own Ruby gem project (namespace is required) [alt: scaffold:gem:cw] ``` -------------------------------- ### Hello, C Tab! - Glimmer DSL for SWT Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This sample demonstrates custom tab widget usage via the `c_tab_folder` and `c_tab_item` variations of `tab_folder` and `tab_item`. These custom tabs allow customization of fonts, background/foreground colors, and display additional tabs that do not fit in the window via a drop down. ```Ruby samples/hello/hello_c_tab.rb ``` -------------------------------- ### Hello, Drag and Drop! - Glimmer DSL for SWT Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This sample demonstrates how to implement drag and drop functionality within a Glimmer DSL for SWT application, enabling intuitive user interaction for moving or copying data. ```Ruby samples/hello/hello_drag_and_drop.rb ``` -------------------------------- ### Hello, Message Box! - Glimmer DSL for SWT Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This sample demonstrates how to display a `message_box` dialog in Glimmer DSL for SWT, useful for user notifications or confirmations. ```Ruby samples/hello/hello_message_box.rb ``` -------------------------------- ### Scaffold a New Glimmer Application Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_COMMAND.md Explains how to generate a new Glimmer application structure from scratch using the `glimmer scaffold[AppName]` command. This process creates essential application files, packages the application for various platforms, and launches it. Users must have Git `user.name` and `github.user` configured. ```Ruby glimmer scaffold[AppName] ``` -------------------------------- ### Run Glimmer Application with JRuby Debugging Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_COMMAND.md Demonstrates how to launch a Glimmer application (`samples/hello/hello_world.rb`) while enabling JRuby's debug option for detailed debugging information. ```Shell glimmer --debug samples/hello/hello_world.rb ``` -------------------------------- ### Package and Distribute Glimmer DSL for SWT Applications Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/README.md This command simplifies the process of creating native-executable packages and distributing Glimmer DSL for SWT applications. It supports Mac and Windows platforms, streamlining the deployment process. ```Shell glimmer package ``` -------------------------------- ### Implement Classic Snake Game with MVP and Data-Binding (Ruby) Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This sample is an implementation of the classic Snake game, demonstrating the Model-View-Presenter (MVP) architectural pattern and data-binding. The application was developed using a test-first approach, highlighting robust software design principles. ```Ruby samples/elaborate/snake.rb ``` -------------------------------- ### Run Glimmer Applications with Raw JRuby Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_COMMAND.md This section details how to execute Glimmer applications directly using the `jruby` command, bypassing the `glimmer` wrapper. It covers variations for Windows/Linux and Mac, including the necessary `-J-XstartOnFirstThread` option for Mac, and how to specify a custom SWT JAR file using `-J-classpath`. The `-r` option preloads the `glimmer-dsl-swt` library, and `-S` specifies the application script. ```Shell jruby -r glimmer-dsl-swt -S application.rb ``` ```Shell jruby -J-XstartOnFirstThread -r glimmer-dsl-swt -S application.rb ``` ```Shell jruby -J-classpath "path_to/swt.jar" -r glimmer-dsl-swt -S application.rb ``` ```Shell jruby -J-XstartOnFirstThread -J-classpath "path_to/swt.jar" -r glimmer-dsl-swt -S application.rb ``` -------------------------------- ### Configure jpackage Extra Arguments in Glimmer Rakefile Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_PACKAGING_AND_DISTRIBUTION.md Demonstrates how to pass additional `jpackage` options, such as license file, Mac signing, and signing key user name, by setting `Glimmer::RakeTask::Package.jpackage_extra_args` in the application's Rakefile. This allows for explicit configuration of the packaging process. ```ruby require 'glimmer/rake_task' Glimmer::RakeTask::Package.jpackage_extra_args = '--license-file LICENSE.txt --mac-sign --mac-signing-key-user-name "Andy Maleh"' ``` -------------------------------- ### Run Glimmer IRB Console (girb) Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/README.md The `girb` command provides an interactive Ruby console specifically designed for prototyping Glimmer DSL for SWT GUI applications. It serves as an alternative to the standard `irb` for Glimmer development. ```Ruby girb ``` -------------------------------- ### Visualize Stock Data with Canvas Path DSL and Background Thread (Ruby) Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This sample implements a Stock Ticker that generates random stock price data for multiple stocks and displays it across four different tab views using the Canvas Path DSL. It utilizes a background thread to continuously update stock prices and dynamically amend the graphed paths, demonstrating real-time data visualization. ```Ruby samples/elaborate/stock_ticker.rb ``` -------------------------------- ### Glimmer DSL for SWT Image Generation and Saving Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/TODO.md Demonstrates how to generate an image using Glimmer DSL for SWT's declarative syntax, draw it onto an SWT `Image` object, and then save it to a file (e.g., 'icon.jpg') using `ImageLoader`. This snippet shows the process of creating a graphical asset and persisting it. ```ruby @i = image(200, 200) {oval(0,0,200,200) {background :red}} # replace with any image like Tetris logo i = org.eclipse.swt.graphics.Image.new(display.swt_display, 200, 200) gc = org.eclipse.swt.graphics.GC.new(i) gc.drawImage(@i.swt_image, 0, 0) il = ImageLoader.new(); il.data = [i.image_data]; il.save('icon.jpg', swt(:image_jpeg)) ``` -------------------------------- ### Configure Glimmer DSL for SWT on Mac Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/README.md This command performs necessary configurations for Glimmer DSL for SWT on macOS. It ensures proper functioning of `glimmer` and `girb` commands by adding `export JRUBY_OPTS="$JRUBY_OPTS -J-XstartOnFirstThread"` to `~/.zprofile` and `~/.bash_profile`. ```Shell glimmer-setup ``` -------------------------------- ### Run Local Girb from Glimmer DSL for SWT Project Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_GIRB.md If you have cloned the `glimmer-dsl-swt` project locally, you can run the `bin/girb` script directly from the project directory to use the Glimmer-specific interactive Ruby shell. ```Shell bin/girb ``` -------------------------------- ### Develop Quarto Game with Canvas Drag and Drop and Custom Shapes (Ruby) Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This sample implements the classic game Quarto, showcasing advanced UI interactions such as Canvas Drag and Drop. It also demonstrates the creation and use of custom shapes like 'cylinder', 'cube', and 'message_box_panel' within an MVC application architecture. ```Ruby samples/elaborate/quarto.rb ``` -------------------------------- ### Packaging Glimmer Applications with Warbler and jpackage Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_PACKAGING_AND_DISTRIBUTION.md Automates the bundling of a Glimmer application into a JAR file using Warbler and subsequently packaging it into native executables (DMG, PKG, APP on Mac; MSI, EXE, APP on Windows; DEB, RPM, APP on Linux) using jpackage. The process generates a JAR in `./dist` and native bundles in `./packages/bundles`. By default, `mac.CFBundleIdentifier` is set to `org.#{project_name}.application.#{project_name}` and the application name is humanized from the root directory. This command also ensures only specific directories (app, config, db, lib, script, bin, docs, fonts, images, sounds, videos) are included by default. ```Shell glimmer package:jar ``` ```Shell glimmer package:native ``` -------------------------------- ### Configuring jpackage Extra Arguments via Rake Task Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_PACKAGING_AND_DISTRIBUTION.md Provides a method to pass additional, custom arguments to the `jpackage` tool by setting `jpackage_extra_args` in the `Rakefile`. This allows for fine-grained control over the native packaging process, such as overriding the Mac bundle identifier or specifying a license file, without re-entering arguments on every run. ```Ruby Glimmer::RakeTask::Package.jpackage_extra_args = " --mac-package-identifier org.andymaleh.application.MathBowling" ``` -------------------------------- ### Run a Glimmer Application File Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_COMMAND.md Executes a Glimmer application file (e.g., `application.rb`) using the `glimmer` command. This automatically preloads the Glimmer Ruby gem and SWT JAR dependencies, providing a convenient way to run applications that might not explicitly require `glimmer-dsl-swt`. ```Shell glimmer application.rb ``` -------------------------------- ### Run a Scaffolded Glimmer Application with glimmer run Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_COMMAND.md Describes the recommended method to execute a Glimmer application after it has been scaffolded or modified. The `glimmer run` command automatically detects and utilizes the generated run script located in the `bin` directory of the application. ```Ruby glimmer run ``` -------------------------------- ### Run Glimmer Package Commands with Bash in Zsh Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_PACKAGING_AND_DISTRIBUTION.md Describes a workaround for Zsh (Z Shell) not honoring `Glimmer::RakeTask::Package.jpackage_extra_args` by running glimmer package commands with a `bash -c` prefix. ```bash bash -c 'source ~/.glimmer_source; glimmer package' ``` -------------------------------- ### Generating and Customizing Warbler Configuration Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_PACKAGING_AND_DISTRIBUTION.md Explains how to generate the `config/warble.rb` file, which holds the JAR packaging configuration. This file allows for explicit customization of included files and directories, such as adding `.env` files or custom asset folders, ensuring all necessary components are bundled. After generation, the file can be manually edited before running `glimmer package`. ```Shell glimmer package:config ``` ```Ruby Warbler::Config.new do |config| # Add .env file config.includes << ".env" # Add an extra directory config.dirs << "my_custom_assets" end ``` -------------------------------- ### Add Glimmer DSL SWT Gem to Gemfile Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/README.md Instructs how to add the `glimmer-dsl-swt` gem to a Ruby project's `Gemfile` for dependency management using Bundler. This is the first step for manual application creation. ```Ruby gem 'glimmer-dsl-swt', '~> 4.30.1.1' ``` -------------------------------- ### Glimmer::Config.logging_device_file_options API Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_CONFIGURATION.md Documents the `logging_device_file_options` configuration option, a hash of `logging` gem options specifically for the `:file` logging device. Useful for customizing file size, age, and rolling behavior. ```APIDOC Glimmer::Config.logging_device_file_options: Hash Description: Options for the :file logging device when using the 'logging' gem. Default: {size: 1_000_000, age: 'daily', roll_by: 'number'} Purpose: Ensures splitting log files at the 1MB size and daily, rolling them by unique number. ``` -------------------------------- ### Hello, List Multi Selection! - Glimmer DSL for SWT Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This sample demonstrates list multi-selection data-binding in Glimmer DSL for SWT, showing how to bind multiple selected items from a list to a model. ```Ruby samples/hello/hello_list_multi_selection.rb ``` -------------------------------- ### Glimmer::Config.logging_devices API Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_CONFIGURATION.md Documents the `logging_devices` configuration option for Glimmer, which specifies an array of logging output destinations when using the `logging` gem. Defaults to `[:stdout, :syslog]`. ```APIDOC Glimmer::Config.logging_devices: Array Description: An array of possible logging output devices. Possible Values: :stdout (default), :stderr, :file, :syslog, :stringio Default: [:stdout, :syslog] Note: If :file is included, a 'log' directory is created. Useful on Windows as an alternative to syslog. ``` -------------------------------- ### jpackage Arguments for macOS Application Signing Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_PACKAGING_AND_DISTRIBUTION.md Details specific `jpackage` command-line arguments required for signing macOS applications. These options enable developers to specify a signing prefix, request signing, define the keychain path, and provide the team name for Apple signing identities, crucial for Mac App Store distribution or notarization. ```APIDOC --mac-package-signing-prefix When signing the application package, this value is prefixed to all components that need to be signed that don't have an existing package identifier. --mac-sign Request that the package be signed --mac-signing-keychain Path of the keychain to search for the signing identity (absolute path or relative to the current directory). If not specified, the standard keychains are used. --mac-signing-key-user-name Team name portion in Apple signing identities' names. For example "Developer ID Application: " ``` -------------------------------- ### Package Glimmer Applications Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_COMMAND.md Glimmer supports packaging applications as native files for Mac and Windows, and as Gem Packaged Shell Scripts for Linux. This command generates a gem for a Glimmer application, which can then be released using `rake release` via Juwelier. ```Shell glimmer package:gem ``` -------------------------------- ### Hello, List Single Selection! - Glimmer DSL for SWT Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This sample demonstrates list single-selection data-binding in Glimmer DSL for SWT, showing how to bind a single selected item from a list to a model. ```Ruby samples/hello/hello_list_single_selection.rb ``` -------------------------------- ### List Available Glimmer DSL Gems Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_COMMAND.md This command lists Glimmer DSL Gems published on rubygems.org, allowing users to discover available DSLs. It can be run with an optional query to filter results. The output provides details such as gem name, version, author, and description. ```Shell glimmer list:gems:dsl[query] ``` ```Shell glimmer list:gems:dsl ``` -------------------------------- ### Display Glimmer Command Usage Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_COMMAND.md Executes the `glimmer` command without arguments to display its usage instructions. On Mac and Linux, it launches a Text-based User Interface (TUI) for interactive task navigation, while on Windows, it lists available tasks. ```Shell glimmer ``` -------------------------------- ### Pass jpackage Extra Arguments via Environment Variable Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_PACKAGING_AND_DISTRIBUTION.md Shows how to provide extra `jpackage` arguments, like overriding the Mac package name, using the `JPACKAGE_EXTRA_ARGS` environment variable. This method offers an alternative to Rakefile configuration for passing packaging options. ```shell JPACKAGE_EXTRA_ARGS='--mac-package-name "Math Bowling Game"' glimmer package ``` -------------------------------- ### Run All RSpec Tests Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/CONTRIBUTING.md Executes the entire RSpec test suite for the Glimmer DSL for SWT project using the Rake build tool. This command ensures all tests pass successfully. ```Ruby rake ``` ```Ruby rake spec ``` -------------------------------- ### Glimmer::Config.logging_appender_options API Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_CONFIGURATION.md Documents the `logging_appender_options` configuration, a hash of options passed to every appender (logging device) used by the `logging` gem, controlling asynchronous behavior, flushing, and immediate logging levels. ```APIDOC Glimmer::Config.logging_appender_options: Hash Description: Options passed as options to every appender (logging device) used in the 'logging' gem. Default: {async: true, auto_flushing: 500, write_size: 500, flush_period: 60, immediate_at: [:error, :fatal], layout: logging_layout} Purpose: Ensures asynchronous buffered logging that is flushed every 500 messages and 60 seconds, or immediately at error and fatal log levels. ``` -------------------------------- ### Invoke Method on Glimmer GUI Widget Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/README.md Widgets in Glimmer GUI DSL have methods to invoke operations, some of which are necessary for display. This snippet shows a `shell` widget with a `text` property, and its `open` method is called to display the window. ```Ruby shell { text 'Hello, World!' }.open ``` -------------------------------- ### Replace Glimmer Logger with Custom Instance Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_CONFIGURATION.md Explains how to replace the default `Glimmer::Config.logger` instance with a custom Ruby `Logger` object. This allows for advanced logging configurations or integration with external logging systems. ```Ruby Glimmer::Config.logger = custom_logger ``` -------------------------------- ### Manually Run a Scaffolded Glimmer Application Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_COMMAND.md Provides several alternative command-line methods for manually launching a scaffolded Glimmer application. These options offer flexibility for running the application directly via JRuby or by explicitly specifying the run script. ```Shell jruby bin/greeter ``` ```Shell bin/greeter ``` ```Shell glimmer bin/greeter ``` ```Shell glimmer run[bin/greeter] ``` -------------------------------- ### Generate DEB Package for Linux Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_PACKAGING_AND_DISTRIBUTION.md Generates a Debian package (DEB) file for Linux distributions that support deb packages, such as Linux Mint Cinnamon or Ubuntu. On Ubuntu, the `fakeroot` package is a prerequisite for this operation. ```Shell glimmer package[deb] ``` -------------------------------- ### Add 'logging' Gem Dependency for Asynchronous Logging Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_CONFIGURATION.md Specifies the `gem` declaration required in a `Gemfile` or similar for integrating the `logging` gem, which provides asynchronous and buffered logging capabilities for Glimmer DSL for SWT applications. ```Ruby gem 'logging', '>= 2.3.0', '< 3.0.0' ``` -------------------------------- ### Declare Glimmer GUI Widget with Keyword Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/README.md Glimmer GUI DSL allows declaring widgets using keywords that represent their underscored names. This snippet demonstrates the basic declaration of a `table` widget. ```Ruby table ``` -------------------------------- ### Run Glimmer Desktopified App Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_COMMAND.md After making changes to a scaffolded Glimmer application, this command runs the app by automatically detecting the generated run script in the 'bin' directory. ```Shell glimmer run ``` -------------------------------- ### Hello, Computed! - Glimmer DSL for SWT Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_SAMPLES.md This sample demonstrates computed data-binding, a Glimmer DSL for SWT feature that automatically updates UI elements based on derived values from other bound properties. ```Ruby samples/hello/hello_computed.rb ``` -------------------------------- ### Generate RPM Package for Linux Source: https://github.com/andyobtiva/glimmer-dsl-swt/blob/master/docs/reference/GLIMMER_PACKAGING_AND_DISTRIBUTION.md Generates a Red Hat Package Manager (RPM) file for Linux distributions that support rpm packages, such as Red Hat Enterprise Linux or Fedora. For Red Hat Linux, the `rpm-build` package is required as a prerequisite. ```Shell glimmer package[rpm] ```