Skip to content

Latest commit

 

History

History
78 lines (46 loc) · 4.27 KB

README.md

File metadata and controls

78 lines (46 loc) · 4.27 KB

gtk-scarpe

Gtk-Scarpe is a specific Scarpe implementation based on GTK4. Scarpe is a reimplementation of Shoes, a Ruby desktop UI library originally written by _why the lucky stiff.

Gtk-Scarpe uses Lacci, the standard Scarpe DSL, and Scarpe-Components. It's a non-HTML-based local display.

Gtk-Scarpe support Shoes-Spec, though only the set of drawables and features currently supported by Gtk-Scarpe.

Installation

Install the gem and add to the application's Gemfile by executing:

$ bundle add gtk-scarpe

If bundler is not being used to manage dependencies, install the gem by executing:

$ gem install gtk-scarpe

Usage

Your application should include gtk-scarpe as a dependency. You can run a Shoes application with gtk-scarpe by using the gtk-scarpe executable:

./exe/gtk-scarpe examples/button_alert.rb

TODO: when gtk-scarpe is tested with Shoes-Spec, .scas and .sspec files, etc. add usage instructions here.

Development

After checking out the repo, run bin/setup to install dependencies. Then, run rake test to run the tests. You can also run bin/console for an interactive prompt that will allow you to experiment.

To install this gem onto your local machine, run bundle exec rake install. To release a new version, update the version number in version.rb, and then run bundle exec rake release, which will create a git tag for the version, push git commits and the created tag, and push the .gem file to rubygems.org.

Writing Specs

Shoes-Spec is the preferred way to write integration tests. To run a Shoes-Spec test, you can use exe/gtk-scarpe. If your filename ends in .sspec and you don't set the environment var SHOES_MINITEST_EXPORT_FILE, Gtk-Scarpe will print your test results to the console:

noah@Noahs-MBP-3 gtk-scarpe % ./exe/gtk-scarpe --dev ../shoes-spec/cases/drawables/button/basic_click.sspec
Test results:
Success!

If there's an exception, skip or failure you should see console results printed as well.

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/scarpe-team/gtk-scarpe. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the code of conduct.

License

The gem is available as open source under the terms of the MIT License.

Code of Conduct

Everyone interacting in the Gtk::Scarpe project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the code of conduct.

Shoes References

Lots of these have great reference code for Shoes and Scarpe, and general Shoes-related information.

GTK+ References

Lots of these have great reference code for Shoes, Scarpe, GTK+ or similar.

Also, when Googling for GTK+ references, keep in mind that GTK+ version 4 ("gtk4") is significantly different from version 2 or version 3. Lots of changes, deprecations and so on. So older code using gtk2 and gtk3 will need updating.