{"id":13806282,"url":"https://github.com/grkek/iu","last_synced_at":"2025-04-19T12:36:14.435Z","repository":{"id":118362581,"uuid":"289542270","full_name":"grkek/iu","owner":"grkek","description":"UI framework based on the Fusion/libui.cr library, with elements from watzon/cru.","archived":false,"fork":false,"pushed_at":"2024-02-19T04:35:11.000Z","size":83,"stargazers_count":73,"open_issues_count":1,"forks_count":5,"subscribers_count":6,"default_branch":"develop","last_synced_at":"2025-03-29T07:51:25.654Z","etag":null,"topics":["crystal","gui","libui","reusable-components","ui","user-interface"],"latest_commit_sha":null,"homepage":"","language":"Crystal","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/grkek.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-08-22T18:12:18.000Z","updated_at":"2025-01-21T13:26:26.000Z","dependencies_parsed_at":null,"dependency_job_id":"a08ef54f-f702-4c5d-8e09-2e37b368c368","html_url":"https://github.com/grkek/iu","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/grkek%2Fiu","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/grkek%2Fiu/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/grkek%2Fiu/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/grkek%2Fiu/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/grkek","download_url":"https://codeload.github.com/grkek/iu/tar.gz/refs/heads/develop","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249694443,"owners_count":21311526,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["crystal","gui","libui","reusable-components","ui","user-interface"],"created_at":"2024-08-04T01:01:09.783Z","updated_at":"2025-04-19T12:36:14.408Z","avatar_url":"https://github.com/grkek.png","language":"Crystal","funding_links":[],"categories":["GUI Development"],"sub_categories":[],"readme":"[![Control gallery](https://i.ibb.co/SNRhTmH/Control-gallery.png)](https://github.com/grkek/iu/blob/develop/examples/control_gallery.cr)\n\n# IU\nUI framework based on the [Fusion/libui.cr](https://github.com/Fusion/libui.cr) library, with custom elements from [watzon/cru](https://github.com/watzon/cru).\n\n## Motivation\nCurrently avaliable Crystal UI frameworks are either not maintained anymore or the documentation is scarce and a single error might cause a developer to lose motivation, which is why I decided to build IU on top of the LibUI framework which is a multi-platform powerful UI toolkit.\n\n## Build status\n[![Build Status](https://action-badges.now.sh/grkek/iu)](https://github.com/grkek/iu/actions)\n\n## Features\n### Widgets\n- Horizontal box, Vertical box, Checkbox, Combobox, Editable combobox.\n- Button, Font button, Color button, Radio button.\n- Datetime picker, Progress bar, Slider, Spinbox.\n- Text entry, Multiline text entry.\n- Form, Grid, Group, Table, Tab, Separator.\n- Image, Label.\n- Window, Menubar, Area.\n- Many more.\n\n### Platforms\n- Mac OSX\n- Linux\n- Windows (Once crystal will be available on Windows)\n\n## Code example\n```ruby\nrequire \"iu\"\n\nmodule Example\n  include Iu::Components\n\n  # Ability to reuse components extracted to other classes.\n  class MyComponent \u003c Iu::ReusableComponent\n    def initialize(@id : Int32); end\n\n    def render : Iu::Component\n      Group\n        .new(title: \"MyComponent\", margined: true)\n        .adopt(\n          VerticalBox\n            .new(padded: true)\n            .adopt(\n              Label.new(text: \"Hello, World ##{@id}!\"),\n              stretchy: true\n            )\n            .adopt(\n              Button.new(text: \"Click Me!\"),\n              stretchy: true\n            )\n        )\n    end\n  end\n\n  # :nodoc:\n  class Application \u003c Iu::Application\n    def initialize_component\n      window =\n        Window.new(\n          title: \"Example\",\n          width: 800,\n          height: 600,\n          menu_bar: false\n        )\n      \n      window.margined = true\n\n      window\n        .adopt(\n          HorizontalBox\n            .new(padded: true)\n            .adopt(\n              MyComponent.new(1),\n              stretchy: true\n            )\n            .adopt(\n              MyComponent.new(2),\n              stretchy: true\n            )\n            .adopt(\n              MyComponent.new(3),\n              stretchy: true\n            )\n        )\n\n      window.closing.on do\n        exit(0)\n      end\n      \n      window.show\n    end\n  end\nend\n\napp = Example::Application.new\n\napp.should_quit.on do\n  exit(0)\nend\n\napp.start\n```\n\n# Installation\n1. Follow the instructions for installation laid out in [andlabs/libui](https://github.com/andlabs/libui).\n2. Copy the compiled files from step 1 (i.e. files in `build/out`) to `/usr/lib` for OSX and Linux users.\n3. Go to your `shard.yml` file, and enter this in:\n\n```yaml\ndependencies:\n  iu:\n    github: grkek/iu\n```\n4. Run `shards install`.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgrkek%2Fiu","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgrkek%2Fiu","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgrkek%2Fiu/lists"}