GithubHelp home page GithubHelp logo

callback for UI.timer about libui HOT 6 CLOSED

kojix2 avatar kojix2 commented on June 18, 2024
callback for UI.timer

from libui.

Comments (6)

AndyObtiva avatar AndyObtiva commented on June 18, 2024 1

I just added support for timer and queue_main block syntax to Glimmer DSL for LibUI today (0.2.0)

Here are examples using it:

https://github.com/AndyObtiva/glimmer-dsl-libui/#timer

https://github.com/AndyObtiva/glimmer-dsl-libui/#color-the-circles

The implementation includes some extra convenience options like specifying repeat option as a finite integer or disabling repetition after one run (currently at the bottom of this file):

https://github.com/AndyObtiva/glimmer-dsl-libui/blob/master/lib/glimmer/libui.rb

So, your implementation in LibUI is more than good enough at the binding layer to enable Glimmer’s code at the higher DSL layer. I don’t think you have to worry about it.

from libui.

kojix2 avatar kojix2 commented on June 18, 2024

An easy way to solve this problem is to override UI#timer.
But before doing that, it would be better to check other callbacks used in libui.
There may be other functions that cause the same problem.

from libui.

kojix2 avatar kojix2 commented on June 18, 2024

Amazing!
You work so fast, I can't keep up with you at all.
Well, I'll take my time.

from libui.

kojix2 avatar kojix2 commented on June 18, 2024
  • uiQueueMain
  • uiOnShouldQuit

from libui.

kojix2 avatar kojix2 commented on June 18, 2024

Maybe I could have solved this issue, but I haven't tested it enough, so I'll wait and see.

from libui.

AndyObtiva avatar AndyObtiva commented on June 18, 2024

Given the Layered Architecture of Glimmer DSL for LibUI, I think we have the following layers from top to bottom, and each is performing its function sufficiently, so I wouldn't worry:

  • DSL (Domain Specific Language) layer for desktop application developers to build GUI with the simplest declarative hierarchical object-oriented syntax possible.
  • Binding layer for mapping C functions to Ruby to make LibUI available in the Ruby programming language.
  • Implementation layer for implementing libui in C on top of each operating system's windowing system.
  • Windowing layer, which varies per operating system (Cocoa on Mac, Win32 on Windows, and GTK on Linux).
  • CPU architecture layer, which varier per CPU hardware (e.g. x86_64 vs Aarch64).

from libui.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.