• Stars
    star
    1,869
  • Rank 24,802 (Top 0.5 %)
  • Language
    C++
  • License
    MIT License
  • Created over 8 years ago
  • Updated over 3 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Node bindings for libui, an awesome native UI library for Unix, OSX and Windows

libui-node

Node.js bindings for libui library.

libui is a lightweight, portable GUI library that uses the native GUI technologies of each platform it supports.

It is in early stage of development, but is evolving at great pace and is really awesome. It could become an awesome alternative to Electron to develop multiplatform GUI, expecially suited to develop small apps.

Travis Build Status AppVeyor Build Status NPM module NPM downloads

Screenshots


macOS

macOS


Linux

Linux


Windows

Windows


Supported platforms

  • Windows: Windows Vista SP2 with Platform Update or newer
  • Unix: GTK+ 3.10 or newer
  • Mac OS X: OS X 10.8 or newer
  • Node.js version 4 or greater.

Prerequisites

Windows

Linux

If they are not provided by default in your distribution:

macOS

Installation

npm install -S libui-node

libui prebuilt binaries are automatically downloaded after install.

If you get this error on Windows:

'__pfnDliNotifyHook2': redefinition; different type modifiers

you need to install latest npm version:

$ npm i -g npm

see this node-gyp issue for more details.

Documentation & examples

Documentation is in docs folder. You can also find working examples in examples folder.

How to run the examples

First, you have to clone the GitHub repo and npm install it:

git clone https://github.com/parro-it/libui-node.git
npm install

Then, to run the control gallery example (requires Node.js >= 6), type:

npm start

For the core api, example, type:

npm run start-core

To run other examples:

node <path to example file>

Contribution & design

  • Each libui control implementation is written in it's own C++ file in src folder.
  • Each control is implemented in it's own C++ class, each class is a simple wrapper of related libui C functions.
  • Header files are in src/includes folder.
  • Control events does not follow node convention: if you attach an handler to an event, previous one will be overwritten and never be called.
  • We build the project using the awesome nbind tool, that automate the process of linking a straight C++ class to Node.js stuff...

Related projects

  • libui - Simple and portable (but not inflexible) GUI library in C that uses the native GUI technologies of each platform it supports.
  • nbind - Magical headers that make your C++ library accessible from JavaScript
  • proton-native - A React environment for cross platform native desktop apps https://proton-native.js.org
  • Vuido - A Vue.js component implementation built on top of LibUI-Node

Contributors

Andrea Parodi | Juha JΓ€rvi | Niklas Mischkulnig | Gustav Hansen ---|---|---|--- Andrea Parodi | Juha JΓ€rvi | Niklas Mischkulnig | Gustav Hansen

License

The MIT License (MIT)

Copyright (c) 2018 parro-it

More Repositories

1

awesome-micro-npm-packages

A curated list of small, focused npm packages.
4,491
star
2

electron-localshortcut

Add keyboard shortcuts locally to a BrowserWindow instance, without using a Menu
JavaScript
410
star
3

canibekikked

Tool to check if any of your NPM repositories name are trademarked
JavaScript
153
star
4

debug-menu

Chrome-like debugging context menu for electron.
JavaScript
135
star
5

electron-input-menu

Context menu for electron input elements.
JavaScript
102
star
6

electron-detach

Restart an electron app as a detached process
JavaScript
59
star
7

electron-google-oauth

Google api access token in electron
JavaScript
56
star
8

open-ssh-tunnel

Easy ssh2 tunneling
JavaScript
54
star
9

amaj

🐱 Ask me about JavaScript 🐱
51
star
10

electron-contextmenu-middleware

Build electron context menus composing multiple middlewares functions.
JavaScript
49
star
11

tunnels

Awesome Electron app to manage your ssh tunnels.
JavaScript
47
star
12

netcdf4

NodeJS addon to read and write NetCDF4 files
C++
39
star
13

libui-napi

Experimental bindings for libui using n-api
C
37
star
14

tape-async

A tiny wrapper around tape to simplify async testing.
JavaScript
32
star
15

folderify

A browserify transform to convert calls to include-folder to inline file content
JavaScript
31
star
16

screen-info

Multiplatform screen & monitors info
JavaScript
30
star
17

hyperterm-title

Set the title of your tabs to what your shell suggests
JavaScript
25
star
18

is-fqdn

Check if a string represent a fully qualified domain name
JavaScript
22
star
19

comws

koa-like generator middlewares for any apps (not just webserver!)
JavaScript
20
star
20

include-folder

expose the content of each file in a folder as an object property
JavaScript
18
star
21

react-libui

An implementation of libui in React.
JavaScript
18
star
22

keyboardevent-from-electron-accelerator

Transform an Electron Accelerator string into a DOM KeyboardEvent.
JavaScript
13
star
23

private-class

Protect private properties of classes
JavaScript
8
star
24

gravity-func

functional utility for gravity
Swift
7
star
25

nice-dialogs

Awesome replace for alert, confirm, prompt js commands
JavaScript
7
star
26

npm-exists

check if a library exists on npm
JavaScript
7
star
27

command-palette

Awesome Sublime like command palette written in plain javascript
JavaScript
5
star
28

babelplugin-to-eslintrule

Map babel plugins to corresponding eslint ecmaFeatures
JavaScript
5
star
29

spawn-shell

Run shell commands using child_process#spawn.
JavaScript
4
star
30

git-credential-node

Thin wrapper around `git credential` command
JavaScript
4
star
31

readline-completer

Better tab completion for node readline
JavaScript
4
star
32

map-array

Map object keys and values into an array.
JavaScript
4
star
33

termite

Electron terminal emulator
JavaScript
3
star
34

libui-download

Downloads a libui release zip from github
JavaScript
3
star
35

libdesktop

C
3
star
36

iterable-lookahead

Iterable wrapper that add methods to read ahead or behind current item.
JavaScript
3
star
37

ai-fun

A collection of modules to easy deal with async iterables
Shell
3
star
38

unthis

Given a method, return a function that accept `this` as last argument
JavaScript
3
star
39

px

Posix cross platform npm scripts.
JavaScript
2
star
40

canibekikked-api

API module of canibekikked
JavaScript
2
star
41

jgoban

html5 goban
JavaScript
2
star
42

eslint-config-features

Automatically configure eslint ecmaFeatures according to package.json `engines` field.
JavaScript
2
star
43

dotfiles

my dotfiles
Shell
2
star
44

transform-spread-iterable

An iterable transform that spread each iterable received and emit its items
JavaScript
2
star
45

iterable-transform-replace

An iterable transform that apply replace to all items
JavaScript
2
star
46

keyboardevents-areequal

Check if two keyboardevents objects are equals.
JavaScript
2
star
47

mod-scaffold

scaffold node packages
Shell
2
star
48

vs

Go
2
star
49

semver-first-satisfied

Find minimum in an array of version that satisfies a semver range.
JavaScript
2
star
50

map-iterable

Array.prototype.map analog for iterables.
JavaScript
1
star
51

orgame

TypeScript
1
star
52

imap-stream

A readable stream of imap mails
JavaScript
1
star
53

templatedir

Templare aids you in making GH repos from GH template repos.
Go
1
star
54

shell-quote-word

unquote a single shell arguments
JavaScript
1
star
55

fileargs

fileargs allows to parse form text and to format to text a struct FileArgs
Go
1
star
56

dotfiles.2020

modern 2020 dotfiles
Shell
1
star
57

prova

ennesima porova
1
star
58

file-to-datauri

Convert local files into data uris with ease.
JavaScript
1
star
59

ncdf

Go
1
star
60

posta

Go
1
star
61

gomodexample2

gomodexample2
Go
1
star
62

babelify-require

Apply babel to a module and then require it.
JavaScript
1
star
63

asynciterable

Basic async iterable class with buffer.
JavaScript
1
star
64

ebansoft.com

ebansoft.com blog source code
CSS
1
star
65

ai-event

Create an async iterable from an event emitter.
JavaScript
1
star
66

imap-parsed-stream

JavaScript
1
star
67

libui-richtexteditor

CMake
1
star
68

ai-from-stream

create an async iterable from a stream
JavaScript
1
star
69

gomodexample

gomodexample is an example go module created with github.com/parro-it/gomod gomod template.
Go
1
star
70

throttle-override

returns a function that will can only be called a certain amount of times per second
JavaScript
1
star