Skip to content

Commit

Permalink
Rename to Orbment.
Browse files Browse the repository at this point in the history
  • Loading branch information
Cloudef committed Mar 6, 2015
1 parent f0e9aeb commit 804fa4a
Show file tree
Hide file tree
Showing 13 changed files with 118 additions and 107 deletions.
16 changes: 8 additions & 8 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
CMAKE_MINIMUM_REQUIRED(VERSION 2.8)
PROJECT(loliwm C)
set(LOLIWM_NAME "loliwm")
set(LOLIWM_DESCRIPTION "Simple tiling compositor for wayland")
set(LOLIWM_VERSION "0.0.1")
set(LOLIWM_PLUGINS_PATH "${CMAKE_INSTALL_PREFIX}/lib/loliwm" CACHE STRING "Systemwide plugins path")
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${loliwm_SOURCE_DIR}/CMake)
PROJECT(orbment C)
set(ORBMENT_NAME "Orbment")
set(ORBMENT_DESCRIPTION "Modular Wayland Compositor")
set(ORBMENT_VERSION "0.0.1")
set(ORBMENT_PLUGINS_PATH "${CMAKE_INSTALL_PREFIX}/lib/orbment" CACHE STRING "Systemwide plugins path")
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${orbment_SOURCE_DIR}/CMake)

# Includes
include(subproject)
Expand All @@ -28,5 +28,5 @@ add_subdirectory(lib)
add_subdirectory(src)
add_subdirectory(plugins)

install(FILES loliwm.1 DESTINATION man/man1)
install(DIRECTORY include/loliwm DESTINATION include)
install(FILES orbment.1 DESTINATION man/man1)
install(DIRECTORY include/orbment DESTINATION include)
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
loliwm, wayland compositor
Orbment, Modular Wayland compositor
Copyright (C) 2014 Jari Vetoniemi

This program is free software: you can redistribute it and/or modify
Expand Down
18 changes: 9 additions & 9 deletions README.rst
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.. |build| image:: http://build.cloudef.pw/build/loliwm/master/linux%20x86_64/current/build-status.png
.. |build| image:: http://build.cloudef.pw/build/loliwm/master/linux%20x86_64/current/build-status.png
.. _build: http://build.cloudef.pw/build/loliwm/master/linux%20x86_64

.. image:: http://cloudef.pw/armpit/loliwm-gh.png
Expand All @@ -9,7 +9,7 @@
OPTIONS
-------

Basic information about what you can currently do in loliwm.
Basic information about what you can currently do in Orbment.

+-----------------------+------------------------------------------------+
| ``--prefix MODIFIER`` | Set the modifier(s) to use with the keybinds. |
Expand All @@ -30,7 +30,7 @@ wlc specific env variables
+------------------+------------------------------------------------------+
| ``WLC_XWAYLAND`` | Set 0 to disable Xwayland. |
+------------------+------------------------------------------------------+
| ``WLC_DIM`` | Brightness multiplier for dimmed views (0.5 default) |
| ``WLC_DIM`` | Brightness multiplier for dimmed views (0.5 default) |
+------------------+------------------------------------------------------+

KEYBINDS
Expand Down Expand Up @@ -65,7 +65,7 @@ Note that these keybinds are temporary until configuration is added.
+-----------------+------------------------------------------------------+
| ``mod-print`` | Takes a screenshot in PPM (Portable Pixmap) format. |
+-----------------+------------------------------------------------------+
| ``mod-esc`` | Quits ``loliwm``. |
| ``mod-esc`` | Quits ``Orbment``. |
+-----------------+------------------------------------------------------+

KEYBOARD LAYOUT
Expand All @@ -75,13 +75,13 @@ You can set your preferred keyboard layout using ``XKB_DEFAULT_LAYOUT``.

.. code:: sh
XKB_DEFAULT_LAYOUT=gb loliwm
XKB_DEFAULT_LAYOUT=gb orbment
RUNNING ON TTY
--------------

Running on TTY works right now.
You need to suid the loliwm binary to whichever group or user has rights to /dev/input.
You need to suid the orbment binary to whichever group or user has rights to /dev/input.
This is so wlc can spawn child process at start that gives rights for libinput to read from these raw input devices.

BUILDING
Expand All @@ -108,7 +108,7 @@ You will also need these for building, but they are optional runtime:

For weston-terminal and other wayland clients for testing, you might also want to build weston from git.

You can build bootstrapped version of ``loliwm`` with the following steps.
You can build bootstrapped version of ``Orbment`` with the following steps.

.. code:: sh
Expand All @@ -118,9 +118,9 @@ You can build bootstrapped version of ``loliwm`` with the following steps.
make # - compile
# You can now run
./src/loliwm
./src/orbment
For proper packaging ``wlc`` and ``loliwm`` should be built separately.
For proper packaging ``wlc`` and ``Orbment`` should be built separately.
Instructions later...

SIMILAR SOFTWARE
Expand Down
19 changes: 15 additions & 4 deletions include/loliwm/plugin.h → include/orbment/plugin.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#ifndef __loliwm_plugin_h__
#define __loliwm_plugin_h__
#ifndef __orbment_plugin_h__
#define __orbment_plugin_h__

#include <stddef.h>
#include <stdint.h>
Expand All @@ -14,6 +14,7 @@ struct method {
struct method_info {
const char *name, *signature;
} info;
bool deprecated;
};

/**
Expand All @@ -30,6 +31,11 @@ struct plugin_info {
*/
const char *name;

/**
* Description of the plugin.
*/
const char *description;

/**
* Version of the plugin.
* XXX: Semantic version?
Expand Down Expand Up @@ -154,7 +160,12 @@ void* import_method(plugin_h plugin, const char *name, const char *signature);
*
* Of course, it is always good idea to check source of your plugins.
*/
#define REGISTER_METHOD(x, y) { .info = { .name = #x, .signature = y }, .function = x }
#define REGISTER_METHOD(x, y) { .info = { .name = #x, .signature = y }, .function = x, .deprecated = false }

/**
* Same as above, but marks as deprecated.
*/
#define REGISTER_DEPRECATED(x, y) { .info = { .name = #x, .signature = y }, .function = x, .deprecated = true }

/**
* Helper macro for filling method_info struct, mainly for has_methods function.
Expand All @@ -163,4 +174,4 @@ void* import_method(plugin_h plugin, const char *name, const char *signature);
*/
#define METHOD(x, y) { .name = x, .signature = y }

#endif /* __loliwm_plugin_h__ */
#endif /* __orbment_plugin_h__ */
2 changes: 1 addition & 1 deletion lib/chck/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
add_library(chck_loliwm STATIC src/chck/pool/pool.c src/chck/string/string.c src/chck/dl/dl.c src/chck/lut/lut.c src/chck/xdg/xdg.c)
add_library(chck_orbment STATIC src/chck/pool/pool.c src/chck/string/string.c src/chck/dl/dl.c src/chck/lut/lut.c src/chck/xdg/xdg.c)
16 changes: 8 additions & 8 deletions loliwm.1 → orbment.1
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
.TH loliwm 1 "October 25" loliwm
.TH orbment 1 "October 25" orbment
.SH NAME
loliwm \- Dynamic wayland compositor.
Orbment \- Dynamic wayland compositor.
.SH SYNOPSIS
\fBloliwm\fP [options]
\fBorbment\fP [options]
.SH DESCRIPTION
\fBloliwm\fP is a dynamic window manager and compositor for Wayland built using
\fBorbment\fP is a dynamic window manager and compositor for Wayland built using
the wlc library.
.SH OPTIONS
.IP "\fB\-\-prefix\fR \fImodifier\fR
Expand Down Expand Up @@ -50,12 +50,12 @@ Closes the focused client.
Shifts the cut of the nmaster layout to shrink or expand the view.
.IP \fBmod-print\fR
Takes a screenshot in PPM (Portable Pixmap) format and stores it in the directory
loliwm was started from.
Orbment was started from.
.IP \fBmod-escape\fR
Quits \fBloliwm\fR.
Quits \fBOrbment\fR.
.SH ENVIRONMENT
.IP \fBTERMINAL\fR
Currently \fBloliwm\fR will honor this environment variable when starting a new
Currently \fBOrbment\fR will honor this environment variable when starting a new
terminal emulator. If this is not set it will fall back on \fBweston-terminal\fR.
.IP \fBWLC_BG\fR
Takes a boolean \fI0\fR or \fI1\fR which disables or enables the background.
Expand All @@ -65,7 +65,7 @@ Takes a boolean \fI0\fR or \fI1\fR, true forces EGL clients to fallback to shm.
(Default: \fI0\fR)
.IP \fBWLC_DIM\fR
Takes an interval between \fI0.0\fR and \fI1.0\fR to define the dullness and
brightness of the dimming effect on unfocused clients respectively. (Default:
brightness of the dimming effect on unfocused clients respectively. (Default:
\fI0.5\fR)
.IP \fBWLC_DEBUG\fR
Takes a comma-separated list of values which enable tracing activity on the
Expand Down
4 changes: 2 additions & 2 deletions plugins/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ set(plugins

include_directories(
${WLC_INCLUDE_DIRS}
${loliwm_SOURCE_DIR}/include
${loliwm_SOURCE_DIR}/lib/chck/src
${orbment_SOURCE_DIR}/include
${orbment_SOURCE_DIR}/lib/chck/src
)

set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/plugins)
Expand Down
6 changes: 3 additions & 3 deletions plugins/core-layouts/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
add_library(loliwm-plugin-core-layouts SHARED core-layouts.c)
set_target_properties(loliwm-plugin-core-layouts PROPERTIES PREFIX "")
install(TARGETS loliwm-plugin-core-layouts DESTINATION ${LOLIWM_PLUGINS_PATH})
add_library(orbment-plugin-core-layouts SHARED core-layouts.c)
set_target_properties(orbment-plugin-core-layouts PROPERTIES PREFIX "")
install(TARGETS orbment-plugin-core-layouts DESTINATION ${ORBMENT_PLUGINS_PATH})
19 changes: 10 additions & 9 deletions plugins/core-layouts/core-layouts.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#include <assert.h>
#include <wlc/wlc.h>
#include <chck/math/math.h>
#include <loliwm/plugin.h>
#include <orbment/plugin.h>

static struct {
struct {
Expand Down Expand Up @@ -118,11 +118,11 @@ plugin_deinit(void)
bool
plugin_init(void)
{
plugin_h loliwm;
if (!(loliwm = import_plugin("loliwm")))
plugin_h orbment;
if (!(orbment = import_plugin("orbment")))
return false;

if (!has_methods(loliwm,
if (!has_methods(orbment,
(const struct method_info[]){
METHOD("add_layout", "b(c[],p)|1"),
METHOD("remove_layout", "v(c[])|1"),
Expand All @@ -133,11 +133,11 @@ plugin_init(void)
}))
return false;

relayout = import_method(loliwm, "relayout", "v(h)|1");
add_layout = import_method(loliwm, "add_layout", "b(c[],p)|1");
remove_layout = import_method(loliwm, "remove_layout", "v(c[])|1");
add_keybind = import_method(loliwm, "add_keybind", "b(c[],c[],p,ip)|1");
remove_keybind = import_method(loliwm, "remove_keybind", "v(c[])|1");
relayout = import_method(orbment, "relayout", "v(h)|1");
add_layout = import_method(orbment, "add_layout", "b(c[],p)|1");
remove_layout = import_method(orbment, "remove_layout", "v(c[])|1");
add_keybind = import_method(orbment, "add_keybind", "b(c[],c[],p,ip)|1");
remove_keybind = import_method(orbment, "remove_keybind", "v(c[])|1");

for (size_t i = 0; layouts[i].name; ++i)
if (!add_layout(layouts[i].name, layouts[i].function))
Expand All @@ -155,6 +155,7 @@ plugin_register(void)
{
static const struct plugin_info info = {
.name = "core-layouts",
.description = "Provides core set of layouts.",
.version = "1.0.0",
};

Expand Down
18 changes: 9 additions & 9 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
set(sources
loliwm.c
orbment.c
plugin.c
)

Expand All @@ -8,21 +8,21 @@ configure_file(config.h.in config.h @ONLY)
include_directories(
${WLC_INCLUDE_DIRS}
${WAYLAND_SERVER_INCLUDE_DIR}
${loliwm_SOURCE_DIR}/include
${loliwm_SOURCE_DIR}/lib/chck/src
${orbment_SOURCE_DIR}/include
${orbment_SOURCE_DIR}/lib/chck/src
${CMAKE_CURRENT_BINARY_DIR}
)

add_executable(loliwm ${sources})
add_executable(orbment ${sources})

target_link_libraries(loliwm
chck_loliwm
target_link_libraries(orbment
chck_orbment
${WLC_LIBRARY}
${WLC_LIBRARIES}
)

# Install rules
install(TARGETS loliwm DESTINATION bin)
install(TARGETS orbment DESTINATION bin)

if (UNIX)
# chown to root and setid for group
Expand All @@ -33,7 +33,7 @@ if (UNIX)
# If you have install that does not need permissions to access /dev/input,
# you can forget about this step totally.
install(CODE "
execute_process(COMMAND chown root ${CMAKE_INSTALL_PREFIX}/bin/loliwm)
execute_process(COMMAND chmod g+s ${CMAKE_INSTALL_PREFIX}/bin/loliwm)
execute_process(COMMAND chown root ${CMAKE_INSTALL_PREFIX}/bin/orbment)
execute_process(COMMAND chmod g+s ${CMAKE_INSTALL_PREFIX}/bin/orbment)
")
endif ()
8 changes: 4 additions & 4 deletions src/config.h.in
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#ifndef __config__
#define __config__
#ifndef __orbment_config__
#define __orbment_config__

#define PLUGINS_PATH "@LOLIWM_PLUGINS_PATH@"
#define PLUGINS_PATH "@ORBMENT_PLUGINS_PATH@"

#endif /* __config__ */
#endif /* __orbment_config__ */
Loading

0 comments on commit 804fa4a

Please sign in to comment.