Giter Club home page Giter Club logo

winit-next's Introduction

Exploring approaches to winit API

This is just a prototype showing my vision for the future winit API. The API itself is just rough idea on how it may look like

The design is motivated by endless amount of issues where we need to model feedback between the user and application and by the fact that GUI is generally single threaded.

The desired layout:

  • winit-core - top-level traits not tied to any platform and ideally free from platform extensions.
  • winit - glue around event loop creation in a cross platform way and managing extensions.
  • winit-wayland - wayland backend implementing winit-core. Same should be done for other backends.
  • winit-examples - examples for winit.

The example lives in the winit-wayland, but it'll be moved once the glue API is designed.

winit-next's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

winit-next's Issues

User event handling with the trait approach

Generally one may use an associated type or generic on the event loop, but it'll make API a bit complex and more prone to not being object safe, since the intention is to rely on &dyn T a lot.

I think what we can do is to develop an interface to Wakeup the event loop and then just notify that the loop got woken up, then the users can drain their sources of user events, like channels, Mutex<Vec>, etc.

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.