All Projects → markehammons → Skylight

markehammons / Skylight

Licence: mit
A tutorial wayland based window manager based off Wayland McWayface

Programming Languages

java
68154 projects - #9 most used programming language
scala
5932 projects

Labels

Projects that are alternatives of or similar to Skylight

Programminglanguage Series
📚 编程语言语法基础与工程实践,JavaScript | Java | Python | Go | Rust | CPP | Swift
Stars: ✭ 643 (+2373.08%)
Mutual labels:  jvm
Flix
The Flix Programming Language
Stars: ✭ 719 (+2665.38%)
Mutual labels:  jvm
Titanoboa
Titanoboa makes complex workflows easy. It is a low-code workflow orchestration platform for JVM - distributed, highly scalable and fault tolerant.
Stars: ✭ 787 (+2926.92%)
Mutual labels:  jvm
Kotlinmultiplatform
Kotlin MultiPlatform App (Android, iOS, JVM & JS). MVVM/MVP - Kotlin MultiPlatform
Stars: ✭ 661 (+2442.31%)
Mutual labels:  jvm
Jcsprout
👨‍🎓 Java Core Sprout : basic, concurrent, algorithm
Stars: ✭ 26,536 (+101961.54%)
Mutual labels:  jvm
Android Notes
✨✨✨这有一包小鱼干,确定不要吃嘛?( 逃
Stars: ✭ 732 (+2715.38%)
Mutual labels:  jvm
Robovm
Ahead of time compiler for JVM bytecode targetting iOS, Mac OSX and Linux
Stars: ✭ 633 (+2334.62%)
Mutual labels:  jvm
Wasm2kt
Web Assembly to Kotlin and Java converter. Allows to compile a C or C++ program/library, and generate a Kotlin or Java program/library.
Stars: ✭ 18 (-30.77%)
Mutual labels:  jvm
Dc Notes
自己的学习笔记。包含:21届秋招经历、🐂客面经问题按照频率总结、Java一系列知识、数据库、分布式、微服务、前端、技术面试、工具教程等(持续更新)
Stars: ✭ 714 (+2646.15%)
Mutual labels:  jvm
Java Knowledge Mind Map
【🌱🌱Java服务端知识技能图谱】用思维脑图梳理汇总Java服务端知识技能
Stars: ✭ 787 (+2926.92%)
Mutual labels:  jvm
Es4x
🚀 fast JavaScript 4 Eclipse Vert.x
Stars: ✭ 669 (+2473.08%)
Mutual labels:  jvm
Arthas
Alibaba Java Diagnostic Tool Arthas/Alibaba Java诊断利器Arthas
Stars: ✭ 27,984 (+107530.77%)
Mutual labels:  jvm
Ringojs
RingoJS is a JavaScript platform built on the JVM and optimized for server-side applications.
Stars: ✭ 777 (+2888.46%)
Mutual labels:  jvm
Java Virtual Machine Specification
Chinese translation of The Java® Virtual Machine Specification.《Java 虚拟机规范(第11版)》中文翻译及示例,Java SE 11 版
Stars: ✭ 649 (+2396.15%)
Mutual labels:  jvm
Assimp
The official Open-Asset-Importer-Library Repository. Loads 40+ 3D-file-formats into one unified and clean data structure.
Stars: ✭ 7,309 (+28011.54%)
Mutual labels:  jvm
Intellij Jvm Options Explained
Common JVM options used with Intellij and what they do
Stars: ✭ 636 (+2346.15%)
Mutual labels:  jvm
Lucee
Lucee Server is a dynamic, Java based (JSR-223), tag and scripting language used for rapid web application development. Lucee simplifies technologies like webservices (REST, SOAP, HTTP), ORM (Hibernate), searching (Lucene), datasources (MSSQL, Oracle, MySQL and others), caching (infinispan, ehcache, and memcached) and many more. Lucee provides a compatibility layer for Adobe ColdFusion © CFML using less resources and delivering better performance.
Stars: ✭ 719 (+2665.38%)
Mutual labels:  jvm
Loom
https://openjdk.java.net/projects/loom/
Stars: ✭ 921 (+3442.31%)
Mutual labels:  jvm
Scala Logging
Convenient and performant logging library for Scala wrapping SLF4J.
Stars: ✭ 804 (+2992.31%)
Mutual labels:  jvm
Korge
KorGE Game Engine. Multiplatform Kotlin Game Engine
Stars: ✭ 780 (+2900%)
Mutual labels:  jvm

Skylight

This is an implementation of Wayland McWayface Part 3 by Drew DeVault. In order to have bindings of wlroots and wayland within java, I've made use of the jextract utility provided by project panama. However, I've also made use of the foreign api directly as well, which can be seen in usr.include.stdlib in the scala sources.

In the future, this project will become it's own thing, taking some cues from tinywm by the wlroots project.

Dependencies

In order to build and run this project you will need build ea+70 of project panama on jdk 13. You'll also need the wayland development libraries, the wlroots library and development libraries, clang, libpixman's development libraries, libxkbcommon and possibly others.

Building

Run sbt compile in the root of the project directory to build the project.

Check the following settings in build.sbt if build fails:

xdgShellProtocolLocation := file("/usr/share/wayland-protocols/unstable/xdg-shell/xdg-shell-unstable-v6.xml")

includeDirectory := file("/usr/include")

libraryDirectory := file("/usr/lib64")

Make sure they point to your xdg-shell-unstable-v6.xml, your include path, and the path that contains the .so files on your system.

Implementation

I have implemented the Wayland McWayface part 3 demo as written here for the most part. Below are the list of changes I've made...

  • wl_container_of is not used in some places where the original demo uses it. The following implementation...

    static void output_frame_notify(struct wl_listener *listener, void *data) {
         struct mcw_output *output = wl_container_of(listener, output, frame);
    

    has changed to...

    lazy val output_frame_notify: FI5 = (_: Pointer[wl_listener], data: Pointer[_]) => {
    

    I've made this change because scala has closures and mcw_output would have to become a C struct in order to retrieve it from the listener embedded within it.

  • mcw_output does not have a link member because we store it in outputs: Set[mcw_output] within mcw_server instead a wl_list.

  • I use constructors for mcw_server and mcw_output instead of treating them as structs.

  • I've implemented wl_signal_add in my code because it is inlined in the original library.

  • I've implemented wl_container_of in my code because it's a macro in the original wayland library.

  • There are a few api changes from the original tutorial because the wlroots api has changed between version 0.2 (which was used in Drew DeVault's tutorial) and version 0.3. This project targets wlroots version 0.3

Notes

In part 3 it shows using gnome-terminal with wayland mcwayface. I could not get gnome-terminal working, but weston-terminal works just fine:

Imgur

Also, I've added wl_display_terminate to the output_destroy_notify callback in order to have the WindowManager close when the display is closed.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].