summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2013-03-09font: pango: fix vertical alignment of non-ASCII glyphsChang Liu1-1/+1
pango_ft2_render_layout_line() requires the baseline offset as argument, not the vertical extent of the glyphs. This is important as we currently align glyphs to the bottom edge instead of the baseline. Fix this by passing the cached baseline offset so all glyphs are correctly aligned to the baseline. We then clip according to the cell-extents as usual. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-09wlt: theme: change frame color to white plus black borderDavid Herrmann1-8/+23
It is currently pretty annoying to use multiple wlterm windows stacked on top on each other when the terminal-background is black. The border doesn't use multiple colors so it is hard to distinguish from the main-frame. This patch changes the border color to white (as most terminal-backgrounds are black by default) and additionally draws a black 1px frame around it. This guarantees that the frame is even visible with white terminal backgrounds. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-08build: fix binary-link with ld.gold linkerDavid Herrmann1-5/+30
The ld.gold linker doesn't provide --format=default but needs --format=elf instead. However, this doesn't work with ld.bfd. To avoid any linker detection, we now link any binary file via partial-linking into a proper object file itself and then link this object file in the final linking step. This also produces a fake libtool *.lo file so the libtool linking command doesn't complain about PIC/non-PIC problems. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-06uvtd: vt: return -ENODEV if session diedDavid Herrmann1-0/+37
We now keep a link to our parent seat and set it to NULL when our session is unregistered. In this case, any further request that depends on the session being registered and probably a valid seat pointer, we will stop with ENODEV. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-06uvtd: vt: implement VT_GETMODE/SETMODE ioctl state-trackingDavid Herrmann3-5/+42
These ioctls are used to retrieve and set the VT-mode. That is, the signals and PID information that correspond to the VT controlling process. It is notified whenever the VT gets active/inactive so it can react to it or prevent/acknowledge it. This doesn't implement the signal-sending logic, yet. It only implements state-tracking. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-06uvtd: seat: implement session IDsDavid Herrmann1-9/+45
Session IDs provide a unique ID for each registered session. They are used to sort the sessions so next/prev return the correct neighbour-sessions. Furthermore, they can be used by outside users to refer to a session directly without knowing the session implementation. Sessions with ID=0 are always linked at the end and considered to be "unnamed". The algorithm to switch to a session with a given ID is: Try to find the first session with the exact same ID. If there is none, return the session with the next higher ID. If there is none, return the ID'th session in the list. If there is none, return the last session. This provides a fairly predictable way of switching between session. It is modeled after the classic VT F1-F12 keys that switch between sessions. If a session is not given, these keys will switch to the next higher session instead. All "unnamed" sessions are put at the end. So if you have only F1-F4, then F5-F12 will map to unnamed sessions. Please note that new sessions are always linked at the end of their group. So new unnamed sessions are at the far end, new named sessions are linked in the sorted list but behind all sessions with the same ID. Hence, the caller should avoid multiple sessions with the same ID, otherwise, some sessions might not be reachable even though they're named (unless you use next/prev of course). Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-06uvtd: vt: implement ioctl dummiesDavid Herrmann1-0/+131
Add dummies for the ioctl VT callbacks. Also implement the KD-MODE and KB-MODE state tracking as it is fairly trivial. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-06wlt: theme: prevent move/resize requests when maximized/fullscreenDavid Herrmann1-0/+5
We should let the user move or resize the window while it is fullscreen or maximized. This depends on the compositor to stop pending move/resize requests when maximizing or setting a window fullscreen. We can implement some "snap away from edges" behavior that allows to move or resize while maximized. This will "unmaximize" the window if you move it more than a given threshold. However, that's not needed now so lets do that later when the wl_shell system is fully figured out. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-06wlt: toolkit: add is_maximized/fullscreen helpersDavid Herrmann2-0/+12
These helpers return whether a window is maximized/fullscreen. This can be used by the theme/terminal control layer to change behavior depending on these flags. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-06tsm: vte: fix g0-g3 character-set shiftingDavid Herrmann1-29/+29
A terminal's GL and GR sets can be mapped to 4 different registers g0 to g3. The g0-g3 registers can be freely set by the application to predefined or uploaded character-sets. We implemented GL and GR as separate registers that are set to the current g0-g3 states when the applications requests a remapping. So subsequent changes to g0-g3 don't affect GL and GR. Unfortunately, it turns out this is wrong. GL and GR should point to the g0-g3 registers instead of copying them. This commit fixes the GL and GR pointers to point to g0-g3 instead of pointing to the underlying character sets. This fixes line-drawing applications like alsamixer, make-menuconfig and other ncurses based software. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-05uvt: client: implement major ioctl callbacksDavid Herrmann2-86/+272
Add callbacks for all major ioctls. We currently only implement ioctls that are used by xserver on linux machines. Feel free to implement the new ioctls. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-05uvtd: ctx: link control/legacy nodes with VTsDavid Herrmann2-49/+246
We now create a VT for each legacy node and assign all clients to it. For control nodes, we create a different VT for each open-file/client. Note that we do not recreate VTs or CDEVs directly on HUP instead of during the next open() or reconfiguration. This avoids trapping into the same error again and gives control to the user to recreate the nodes at the right time. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-05uvtd: add VT subsystemDavid Herrmann3-0/+272
The VT subsystem manages the virtual VTs and registers them with the seat/session-scheduler. They manage control and legacy nodes as they are mostly the same. The different contexts create these VTs and assign them to cdev clients. This allows us to split the VT and cdev logic apart so they can be assigned freely to different clients. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-05uvt: client: export symbolsDavid Herrmann2-0/+12
This adds the uvt_client symbols to the public symbol list and exports them so we can use them in uvtd. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-05uvt: client: fix double-kill by first unlinkink then resettingDavid Herrmann1-2/+2
We _must_ unlink the client and cdev first, then reset the VT. Otherwise, the set_vt() call might think we are still alive and call user-defined callbacks which might call kill again. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-05uvt: include inttypes.hDavid Herrmann1-0/+1
We use uint8_t so make sure we include inttypes.h in uvt.h. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-05uvtd: add ctx subsystemDavid Herrmann4-12/+373
The ctx subsystem manages the CDEV devices for each seat. It currently allocates one manager device and a given number of legacy devices that can be accessed via subdirectories. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-05uvt: ctx: add major/minor helpersDavid Herrmann4-0/+56
Two new functions to retrieve the current major number and dynamically allocate minor numbers. This can be used by clients that allocate more than one CDEV for VTs to dynamically retrieve a new minor number. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-05build: add shl_flagset to build-systemDavid Herrmann1-1/+2
We need the shl_flagset as part of SHL to make use of it. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-05uvt: add SHL_EXPORT to cdev+ctx subsystemsDavid Herrmann3-0/+17
We need to export the symbols to make use of them. This exports all useful ctx+cdev functions for outside use. The other subsystems still need to get reviewed before we export them. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-05uvt: cdev: fix sending DEVNAME parameterDavid Herrmann1-1/+1
We used an incorrectly formatted arguments as we mixed up two local variables. Use the correct DEVNAME format now. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-05uvt: cdev: print minor/major debug messagesDavid Herrmann1-2/+2
These numbers are pretty useful during debugging so print them before attempting to create the cdev devices. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-05shl: add flagset helperDavid Herrmann2-0/+136
A flagset is a dynamic array where each bit of the array can be independently set/reset. It can be used for minor/major allocations or for other dynamically growing bitsets. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-05shl: dlist: add _first/_last helpersDavid Herrmann1-0/+6
These helpers return the first and last elements respectively. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-05shl: array: add shl_array_zresize()David Herrmann1-0/+27
This helper resizes the array to a given length and zeroes out all new elements. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-04README: fix tarball-link to /software/kmsconDavid Herrmann1-1/+1
We now have official upload space on freedesktop.org. No need to link to my personal upload space, anymore. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-04build: add .xz files to gitignore instead of bz2David Herrmann1-1/+1
We use .xz now instead of .bz2 for release tarballs. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-04docs: fix links to point to freedesktop.orgDavid Herrmann2-4/+15
kmscon is now hosted on freedesktop.org. Please don't use the github links, anymore. I will push to github for some more weeks, but I recommend to everyone to use my freedesktop.org repository as primary upstream link. There were many reasons why github.com wasn't sufficient, anymore. But the main reason is that they no longer provide upload space for release tarballs. Hence, lets ditch github and move to freedesktop.org which kindly provides everything we need plus a really nice mailing-list. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-04build: use xz tarballs instead of bz2David Herrmann1-1/+1
xz is way better than bz2 with same/better decompression times. Compression will take longer, but that's totally ok. All new tarballs will be provided as xz only. Please adjust your build-scripts to stop using bz2. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-04build: add --enable-allDavid Herrmann2-17/+72
This flag enables all other options that extend the build. It is used for debugging only and should never be used by distributions to control what is built. Hence, we don't document it and never advertise it. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-04tests: use new shl_log.hDavid Herrmann5-5/+6
log.h was moved to shl so use it in all tests. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-04uvtd: add new Virtual Terminal daemonDavid Herrmann6-2/+1006
This introduces uvtd which replaces kmscon sessions as an external helper program. It's still a dummy program but it will get extended soon. After that, kmscon sessions will get removed and limited to a single seat. This will simplify kmscon itself heavily and move rarely used features out of kmscon into helpers. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-04shl: move githead into a source fileDavid Herrmann7-32/+58
This moves githead.h to shl_githead.c so we can skip recompilations on GIT-HEAD changes. We only need to relink now (which we cannot skip). This speeds up build-processes considerably on slower machines. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-04shl: move log.[ch] to shl_log.[ch]David Herrmann47-54/+50
We want to avoid any static files that are shared between multiple programs but are not part of SHL. These make the build-process just more complex. Move log.[ch] to SHL so we have a known context. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-04log: move includes to topDavid Herrmann1-4/+2
There is no reason to include headers in the main body of the source code. Move it to the top so it's more readable. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-03-04build: mark font-unifont as noexecstackDavid Herrmann1-0/+1
ld automatically assumes that any binary input file requires an executable stack. There's no way to tell it that it doesn't so we simply mark all inputs as noexecstack. Reported-by: Etam Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-02-28Release kmscon-7kmscon-7David Herrmann3-2/+9
This is kmscon-7. See ./NEWS for a list of new features. Unfortunately, github disabled the "Downloads" section so there is no way to upload new pre-generated tarballs. I have a pending application to move kmscon to freedesktop.org, but it didn't get processed in time for this release. Therefore, you need to build the GNU-autotools files yourself. That is, before calling ./configure you need to call: NOCONFIGURE=1 ./autogen.sh You can extend your build-scripts with: test -f ./configure || NOCONFIGURE=1 ./autogen.sh Which will call ./autogen.sh if needed. Everything else can be left unchanged. I will not upload the tarballs at another location. Feel free to do that yourself, but I personally think this will introduce more confusion than help. I hope the freedesktop.org move will be soon approved. This will also provide a mailing-list where I can properly announce new releases. Raw tarballs will be available as (without pre-generated autotools): https://github.com/dvdhrm/kmscon/archive/kmscon-7.tar.gz https://github.com/dvdhrm/kmscon/archive/kmscon-7.zip The git-tag is: kmscon-7 You can use my public GPG key to verify the tarballs. As usual, please report bugs to: https://github.com/dvdhrm/kmscon Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-02-27build: fix empty --with-*= argumentsDavid Herrmann1-12/+20
It currently isn't possible to pass empty lists to these arguments as it will then be interpreted as default. Fix this by using "default" if it is empty. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-02-27build: enable static libraries by defaultDavid Herrmann1-1/+1
No reason to disable static libraries. Remove the LT_INIT parameter so we can provide statically linked libraries. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-02-27uvt: new library implementing VTs in user-spaceDavid Herrmann11-0/+2170
UVT is based heavily on the old cdev-sessions. It uses CUSE/FUSE to implement virtual terminals in user-space. This move into a library allows to use it in other projects, too. There is no reason to limit it to kmscon sessions. In fact, we will remove the cdev-sessions, soon and make kmscon a stand-alone terminal emulator without any session capability. Instead, the uvtd program will provide the VT emulation. This library is not finished, nor ready for use. However, feel free to contribute patches so we can eventually release a stable API. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-02-18shl: misc: provide shl_next_pow2()David Herrmann2-16/+18
Move the next_pow2() helper to shl_misc.h so we can use it everywhere. Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
2013-02-16tests: fix compilation with new eloop APIDavid Herrmann1-1/+1
We added llog-data pointers so fix the tests helpers to set it to NULL by default. Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
2013-02-16README: update build-instructionsDavid Herrmann1-16/+17
The build-system changed slightly so update the build-instructions. Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
2013-02-16NEWS: add kmscon-7 notesDavid Herrmann1-0/+59
We changed a whole bunch of stuff since kmscon-6 but most of it still isn't finished (mainly the modularization). However, we definitly need a bugfix-release. Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
2013-02-16build: check for fuse >= 2.9.0David Herrmann1-1/+1
We need "fuse_buf" so check for at least fuse 2.9.0. Reported-by: https://github.com/dvdhrm/kmscon/issues/67 Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
2013-02-16build: enable unifont by defaultDavid Herrmann1-2/+2
Unifont is a very nice font-backend that now has sane compilation times (by using ld directly). It's recommended over 8x16 as it has proper internationalization support. Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
2013-02-11docs: remove pixman commentsDavid Herrmann1-47/+0
We now provide an experimental pixman backend. It still suffers from the same problems but that cannot be fixed easily. Check it out if you want it. Disabled by default, though. Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
2013-02-11Fix several typosJakub Wilk19-49/+49
Provided via github. Fixes typos in documentation and comments. Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
2013-02-08llog: add "data" parameter to pass contextDavid Herrmann20-104/+163
If we allow users to specify log functions, we should also allow them to pass a context. This isn't used internally, but may be needed by external users so provide it. Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
2013-02-06build: add --enable-wlterm to distcheck flagsDavid Herrmann1-0/+1
We should test wlterm when running distcheck so make in mandatory. Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>