DEV Community

kojix2
kojix2

Posted on

Ruby/GTK3 - LinkButton

gem install gtk3

LinkButton

a hyperlink widget.

linkbutton

require 'gtk3'

class LinkButtonWindow < Gtk::Window
  def initialize
    super
    set_title 'LinkButton Demo'
    set_border_width 10

    button = Gtk::LinkButton.new('http://dev.to', 'Visit DEV')
    add button
  end
end

win = LinkButtonWindow.new
win.signal_connect('destroy') { Gtk.main_quit }
win.show_all
Gtk.main
Enter fullscreen mode Exit fullscreen mode

Top comments (0)