]> git.armaanb.net Git - dmenu.git/log
dmenu.git
7 years agodmenu.1: fix -l option
Quentin Rameau [Sat, 8 Oct 2016 12:36:04 +0000 (14:36 +0200)]
dmenu.1: fix -l option

7 years agodie() consistency: always add newline
Hiltjo Posthuma [Fri, 12 Aug 2016 12:39:30 +0000 (14:39 +0200)]
die() consistency: always add newline

7 years agofix crash if negative monitor (< -1) was passed
Hiltjo Posthuma [Tue, 26 Jul 2016 21:13:06 +0000 (23:13 +0200)]
fix crash if negative monitor (< -1) was passed

for example: dmenu -m '-9001'

7 years agoRevert "Print highlighted input text only on single match"
Hiltjo Posthuma [Tue, 26 Jul 2016 21:02:34 +0000 (23:02 +0200)]
Revert "Print highlighted input text only on single match"

This reverts commit a4053bc4e403ae57343f43b7e363a0911bba5a3a.

My bad, was working on the wrong branch and accidently pushed it...
*facepalm*

7 years agoPrint highlighted input text only on single match
Quentin Rameau [Tue, 26 Jul 2016 10:48:23 +0000 (12:48 +0200)]
Print highlighted input text only on single match

When the input text fully matches a single item, do not draw the item
and highlight the input text to show that it matches an item in
opposition to regular input text not matching anything.

7 years agoPartially revert 44c7de3: fix items text width offset calculation
Quentin Rameau [Mon, 25 Jul 2016 09:33:25 +0000 (11:33 +0200)]
Partially revert 44c7de3: fix items text width offset calculation

Without this, we discard the item if it's longer than assigned width
instead of truncating it.

7 years agoconfig.def.h: style improvement, use color Scheme enum
Hiltjo Posthuma [Tue, 28 Jun 2016 15:56:25 +0000 (17:56 +0200)]
config.def.h: style improvement, use color Scheme enum

7 years agofix: Do not crash on e.g. dmenu < /dev/null
S. Gilles [Tue, 28 Jun 2016 05:11:50 +0000 (01:11 -0400)]
fix: Do not crash on e.g. dmenu < /dev/null

7 years agoimport new drw from libsl and minor fixes.
Markus Teich [Sat, 21 May 2016 19:51:14 +0000 (21:51 +0200)]
import new drw from libsl and minor fixes.

- extract drawitem function (code deduplication)
- fix bug where inputw was not correctly calculated from the widest item, but
  just from the one with the longest strlen() which is not the same. It's better
  now, but does not account for fallback fonts, since it would be too slow to
  calculate all the correct item widths on startup.
- minor code style fixes (indentation, useless line breaks)

8 years agoarg.h: fixed argv checks order
Lucas Gabriel Vuotto [Mon, 22 Feb 2016 14:03:36 +0000 (11:03 -0300)]
arg.h: fixed argv checks order

This prevents accessing to a potentially out-of-bounds memory section.

Signed-off-by: Lucas Gabriel Vuotto <l.vuotto92@gmail.com>
8 years agoTypofix
Klemens Nanni [Mon, 11 Jan 2016 12:26:37 +0000 (13:26 +0100)]
Typofix

8 years agoShut up glibc about _BSD_SOURCE being deprecated
Quentin Rameau [Sat, 19 Dec 2015 18:58:03 +0000 (19:58 +0100)]
Shut up glibc about _BSD_SOURCE being deprecated

8 years agoAdd config option for word delimiters
Quentin Rameau [Sat, 19 Dec 2015 08:32:55 +0000 (09:32 +0100)]
Add config option for word delimiters

Let the user configure word boundaries other than ' ', only works with
the portable character set.

8 years agoarg.h: remove unused ARGNUM* macros
Hiltjo Posthuma [Sun, 8 Nov 2015 22:37:47 +0000 (23:37 +0100)]
arg.h: remove unused ARGNUM* macros

8 years agounboolify dmenu
Hiltjo Posthuma [Sun, 8 Nov 2015 22:03:34 +0000 (23:03 +0100)]
unboolify dmenu

8 years agoMakefile: package config.def.h on make dist
Hiltjo Posthuma [Sun, 8 Nov 2015 15:46:34 +0000 (16:46 +0100)]
Makefile: package config.def.h on make dist

8 years agoremove .hgtags file
Hiltjo Posthuma [Sun, 8 Nov 2015 15:44:41 +0000 (16:44 +0100)]
remove .hgtags file

8 years agodmenu.1: clarify monitor numbers are starting from 0 (first mon)
Hiltjo Posthuma [Sat, 7 Nov 2015 11:53:00 +0000 (12:53 +0100)]
dmenu.1: clarify monitor numbers are starting from 0 (first mon)

8 years agofix: multimon: always spawn client on first monitor if specified with -m 0
Hiltjo Posthuma [Sat, 7 Nov 2015 11:43:00 +0000 (12:43 +0100)]
fix: multimon: always spawn client on first monitor if specified with -m 0

This was always broken.

Reproduce:
focus client on second monitor, spawn dmenu with -m 0.

Result:
Old wrong behaviour: dmenu spawns on second monitor (focused client).
Now: dmenu spawns on specified monitor (first).

8 years agodrw: cleanup drw_text, prevent gcc warning false-positive of unused var
Hiltjo Posthuma [Tue, 20 Oct 2015 20:56:57 +0000 (22:56 +0200)]
drw: cleanup drw_text, prevent gcc warning false-positive of unused var

... we don't allow passing text is NULL anymore either, for that behaviour
just use drw_rect() (it is used in dwm).

8 years agodrw: simplify drw_font_xcreate and prevent a potential unneeded allocation
Hiltjo Posthuma [Tue, 20 Oct 2015 20:55:39 +0000 (22:55 +0200)]
drw: simplify drw_font_xcreate and prevent a potential unneeded allocation

8 years agodrw: a valid (non-NULL) Drw and Fnt context must be passed
Hiltjo Posthuma [Tue, 20 Oct 2015 20:53:55 +0000 (22:53 +0200)]
drw: a valid (non-NULL) Drw and Fnt context must be passed

don't do these checks on this level. However for resource drw_*_free
we will allow it.

8 years agoadd sbase-style ecalloc(), calloc: or die
Hiltjo Posthuma [Tue, 20 Oct 2015 20:51:57 +0000 (22:51 +0200)]
add sbase-style ecalloc(), calloc: or die

... remove intermediary variables

8 years agofree schemes as array
Hiltjo Posthuma [Sun, 18 Oct 2015 16:37:20 +0000 (18:37 +0200)]
free schemes as array

this makes it slightly easier to add custom schemes aswell

8 years agofix input text matching
Quentin Rameau [Sun, 4 Oct 2015 12:47:52 +0000 (14:47 +0200)]
fix input text matching

just compare the size of the input string

8 years agofix incorrect ordering of match results
Davide Del Zompo [Sun, 4 Oct 2015 12:01:22 +0000 (14:01 +0200)]
fix incorrect ordering of match results

look for exact matches comparing the user input against the item text

8 years agofix paste from clipboard (ctrl+shift+y)
Hiltjo Posthuma [Sun, 4 Oct 2015 10:32:07 +0000 (12:32 +0200)]
fix paste from clipboard (ctrl+shift+y)

from Joshua Lloret on the ML:

"attached is a small patch to enable pasting from clipboard, as well as primary.

It seems like there was already code in there to allow this, but since there was never any case to match the upper case 'Y', that inline if would always evaluate to false."

8 years agominor style fix
Hiltjo Posthuma [Sun, 27 Sep 2015 22:38:17 +0000 (00:38 +0200)]
minor style fix

8 years agoRemove function prototypes and reorder functions accordingly
FRIGN [Sun, 27 Sep 2015 22:19:36 +0000 (00:19 +0200)]
Remove function prototypes and reorder functions accordingly

8 years agoUntypedef struct item
FRIGN [Sun, 27 Sep 2015 22:15:03 +0000 (00:15 +0200)]
Untypedef struct item

Adds clarity. Typedefs for structs are definitely a discussion matter,
but there's no reason to hide a simple data-structure behind a
meaningless typedef.

8 years agoFix the conversion from microseconds to nanoseconds
Quentin Rameau [Sun, 27 Sep 2015 22:18:35 +0000 (00:18 +0200)]
Fix the conversion from microseconds to nanoseconds

8 years agoReplace deprecated usleep() with nanosleep()
Quentin Rameau [Sun, 27 Sep 2015 22:06:05 +0000 (00:06 +0200)]
Replace deprecated usleep() with nanosleep()

8 years agoconfig.mk: use -std=c99
Hiltjo Posthuma [Sun, 27 Sep 2015 22:02:28 +0000 (00:02 +0200)]
config.mk: use -std=c99

8 years agodmenu: style improvements
Hiltjo Posthuma [Sun, 27 Sep 2015 21:57:39 +0000 (23:57 +0200)]
dmenu: style improvements

- move main to bottom, usage above main.
- dont use variable names with function prototypes.
- space before if, for, while, etc: 'if(' -> 'if ('.

this makes the code-style more consistent

8 years agodrw style improvements
Hiltjo Posthuma [Sun, 27 Sep 2015 21:56:02 +0000 (23:56 +0200)]
drw style improvements

this makes the code-style more consistent aswell.

8 years agoseparate program-specific c99 bool and X11
Hiltjo Posthuma [Sun, 27 Sep 2015 21:02:33 +0000 (23:02 +0200)]
separate program-specific c99 bool and X11

True, False are X11-specific, make sure to use c99 stdbool for
program-specific things.

... also remove left-over vim mode string in config.

8 years agoconfig.mk: fix _XOPEN_SOURCE=700 for getline()
Hiltjo Posthuma [Sun, 27 Sep 2015 20:55:21 +0000 (22:55 +0200)]
config.mk: fix _XOPEN_SOURCE=700 for getline()

8 years agoconfig.mk: improve feature test check
Hiltjo Posthuma [Sun, 27 Sep 2015 20:38:14 +0000 (22:38 +0200)]
config.mk: improve feature test check

this fixes a crash on NetBSD because it requires -D_XOPEN_SOURCE (strdup, usleep).

thanks k0ga and stateless for reporting and fixing this issue!

8 years agoFixed typo introduced by shared code
Eric Pruitt [Thu, 6 Aug 2015 02:19:14 +0000 (19:19 -0700)]
Fixed typo introduced by shared code

8 years agostest: get rid of getopt, use suckless arg.h
Hiltjo Posthuma [Sun, 19 Jul 2015 19:34:51 +0000 (21:34 +0200)]
stest: get rid of getopt, use suckless arg.h

... also some style improvements.

8 years agoconfig.mk: add FREETYPELIBS and FREETYPEINC
Hiltjo Posthuma [Sun, 19 Jul 2015 18:32:08 +0000 (20:32 +0200)]
config.mk: add FREETYPELIBS and FREETYPEINC

These variables make it simpler to change the paths to this for ports.
`pkg-config` is avoided because it sucks, in particular for cross-compilation.

A commented path for *BSD is added, the Xft includes are located at:
/usr/X11R6/include there.

Also already bump the version number to 4.6, a release will come
approximately in August.

8 years agofix prompt color style how it used to be
Hiltjo Posthuma [Sun, 19 Jul 2015 18:29:26 +0000 (20:29 +0200)]
fix prompt color style how it used to be

This is the style how it was before the big Xft change. The colors were
inverted, this was not the case before the change.

Reported by "zvz" on #suckless IRC, thanks!

8 years agoUse libdraw: add Xft and fallback-fonts support to graphics lib
Hiltjo Posthuma [Mon, 4 May 2015 19:54:46 +0000 (21:54 +0200)]
Use libdraw: add Xft and fallback-fonts support to graphics lib

- libdraw, util: add drw.{c,h}, util.{c,h} and update code.
- libdraw: fix drw_rect(): use w and h parameter.
- libdraw: print errstr if last character in string was ":" (sbase).
- libdraw: drw_clr_free() allow valid free(NULL).
- config.def.h: set default font to monospace.
- cleanup() on exit.
- LICENSE: update license string for dmenu -v to 2015.
- LICENSE: add myself to LICENSE

9 years agoapplied Hiltjo's patch as suggested on the ml to fix ControlMask for C-j and C-m
Anselm R Garbe [Wed, 17 Sep 2014 11:40:11 +0000 (13:40 +0200)]
applied Hiltjo's patch as suggested on the ml to fix ControlMask for C-j and C-m

9 years agofix crash with ctrl-enter as input
Hiltjo Posthuma [Thu, 24 Jul 2014 19:10:23 +0000 (19:10 +0000)]
fix crash with ctrl-enter as input

reproduce: ./dmenu; send EOF; press ctrl+enter.

9 years agoupdated copyright notices in LICENSE and dmenu.c file
Anselm R Garbe [Thu, 29 May 2014 16:03:53 +0000 (18:03 +0200)]
updated copyright notices in LICENSE and dmenu.c file

10 years agoapplied Martin Kühl's inverse matching flag to stest
Anselm R Garbe [Tue, 13 Aug 2013 17:15:04 +0000 (19:15 +0200)]
applied Martin Kühl's inverse matching flag to stest

10 years agoapplied Martti Kühne's dmenu monitor patch
Anselm R Garbe [Fri, 2 Aug 2013 20:30:20 +0000 (22:30 +0200)]
applied Martti Kühne's dmenu monitor patch
https://gist.github.com/mar77i/3349298/raw/f6581ca96627f4c71c0bd1faf531daaf2a613b95/monarg.patch becomes upstream now

10 years agoaccepted vi'is exit approach ^[ (suggested by Arkaduisz)
Anselm R Garbe [Fri, 28 Jun 2013 20:06:02 +0000 (22:06 +0200)]
accepted vi'is exit approach ^[ (suggested by Arkaduisz)

11 years agoforgot to add config.def.h, thanks William
Anselm R Garbe [Wed, 17 Apr 2013 19:16:51 +0000 (21:16 +0200)]
forgot to add config.def.h, thanks William

11 years agoadopted Alex Sedov's config.h revival patch to tip
Anselm R Garbe [Wed, 17 Apr 2013 19:04:05 +0000 (21:04 +0200)]
adopted Alex Sedov's config.h revival patch to tip

11 years agoapplied Alex Sedov's Tab buffer termination patch, thanks
Anselm R Garbe [Wed, 17 Apr 2013 18:59:12 +0000 (20:59 +0200)]
applied Alex Sedov's Tab buffer termination patch, thanks

11 years agoapplied multisel patch to mainline
Anselm R Garbe [Wed, 17 Apr 2013 18:56:54 +0000 (20:56 +0200)]
applied multisel patch to mainline

11 years agodmenu_run: Split cache logic to dmenu_path again
Quentin Glidic [Mon, 30 Jul 2012 15:02:12 +0000 (17:02 +0200)]
dmenu_run: Split cache logic to dmenu_path again

This allows to run dmenu_path to update the cache using
a packager manager hook system

11 years agoignore prompt if it is empty in addition to NULL
Moritz Wilhelmy [Tue, 15 May 2012 09:47:54 +0000 (11:47 +0200)]
ignore prompt if it is empty in addition to NULL

12 years ago_POSIX_C_SOURCE=200809L
Connor Lane Smith [Fri, 6 Apr 2012 15:38:01 +0000 (16:38 +0100)]
_POSIX_C_SOURCE=200809L

12 years agolisten for C-S-[jm]
Connor Lane Smith [Fri, 10 Feb 2012 00:37:42 +0000 (00:37 +0000)]
listen for C-S-[jm]

12 years agoadd ^G escape keybinding
Karl F [Thu, 19 Jan 2012 22:52:17 +0000 (22:52 +0000)]
add ^G escape keybinding

12 years agoremove _POSIX_C_SOURCE cflag
Connor Lane Smith [Wed, 18 Jan 2012 23:56:13 +0000 (23:56 +0000)]
remove _POSIX_C_SOURCE cflag

12 years agoupdate version 4.5-hg
Connor Lane Smith [Sun, 8 Jan 2012 12:13:00 +0000 (13:13 +0100)]
update version 4.5-hg

12 years agoconfig.mk cleanup
anselm@garbe.us [Wed, 4 Jan 2012 12:30:47 +0000 (13:30 +0100)]
config.mk cleanup

12 years agoalign M-[hjkl] closer to vi keys
Connor Lane Smith [Mon, 2 Jan 2012 18:48:11 +0000 (19:48 +0100)]
align M-[hjkl] closer to vi keys

12 years agohappy new year!
Connor Lane Smith [Sun, 1 Jan 2012 19:33:56 +0000 (20:33 +0100)]
happy new year!

12 years agoadd Mod1Mask keybindings
Connor Lane Smith [Sun, 1 Jan 2012 19:32:40 +0000 (20:32 +0100)]
add Mod1Mask keybindings

12 years agomerge stest -> default
Connor Lane Smith [Mon, 19 Dec 2011 15:52:48 +0000 (16:52 +0100)]
merge stest -> default

12 years agocomment xdg fallback behaviour
Connor Lane Smith [Mon, 19 Dec 2011 15:05:55 +0000 (16:05 +0100)]
comment xdg fallback behaviour

12 years agostest: restore stream testing
Connor Lane Smith [Fri, 9 Dec 2011 10:49:44 +0000 (11:49 +0100)]
stest: restore stream testing

12 years agofork dmenu_run to disown child shell
Connor Lane Smith [Fri, 9 Dec 2011 10:36:26 +0000 (11:36 +0100)]
fork dmenu_run to disown child shell

12 years agostest: cleanup
Connor Lane Smith [Sun, 27 Nov 2011 22:40:48 +0000 (23:40 +0100)]
stest: cleanup

12 years agostest: remove unneeded lstat
Connor Lane Smith [Sun, 27 Nov 2011 22:37:01 +0000 (23:37 +0100)]
stest: remove unneeded lstat

12 years agosimplify stest
Connor Lane Smith [Sun, 27 Nov 2011 22:35:09 +0000 (23:35 +0100)]
simplify stest

12 years agodmenu_run: use $SHELL
Connor Lane Smith [Wed, 23 Nov 2011 14:17:32 +0000 (15:17 +0100)]
dmenu_run: use $SHELL

12 years agoset window background_pixel
Connor Lane Smith [Wed, 23 Nov 2011 13:40:21 +0000 (14:40 +0100)]
set window background_pixel

12 years agofix dmenu_path exec sh
Connor Lane Smith [Sat, 19 Nov 2011 20:31:18 +0000 (21:31 +0100)]
fix dmenu_path exec sh

12 years agofaster dmenu_run -f
Connor Lane Smith [Sat, 19 Nov 2011 20:24:07 +0000 (21:24 +0100)]
faster dmenu_run -f

12 years agoreplace lsx with stest
Connor Lane Smith [Sat, 19 Nov 2011 18:54:55 +0000 (19:54 +0100)]
replace lsx with stest

12 years agoupdate manpage
Connor Lane Smith [Wed, 16 Nov 2011 10:26:15 +0000 (11:26 +0100)]
update manpage

12 years agolimit direction keys in vline
Connor Lane Smith [Tue, 15 Nov 2011 19:32:39 +0000 (20:32 +0100)]
limit direction keys in vline

12 years agofix C-n / C-p directions (thanks bastien)
Connor Lane Smith [Mon, 14 Nov 2011 19:02:16 +0000 (20:02 +0100)]
fix C-n / C-p directions (thanks bastien)

12 years agonew default colour scheme
Connor Lane Smith [Sun, 13 Nov 2011 23:46:56 +0000 (00:46 +0100)]
new default colour scheme

12 years agomakefile: *.o depend on draw.h
Connor Lane Smith [Wed, 26 Oct 2011 13:16:12 +0000 (14:16 +0100)]
makefile: *.o depend on draw.h

12 years agoadd paste from clipboard
Connor Lane Smith [Wed, 26 Oct 2011 12:28:15 +0000 (13:28 +0100)]
add paste from clipboard

12 years agoadd lots of comments
Connor Lane Smith [Wed, 26 Oct 2011 12:20:14 +0000 (13:20 +0100)]
add lots of comments

12 years agoinput focus: calculate areas of intersection
Connor Lane Smith [Wed, 26 Oct 2011 11:14:50 +0000 (12:14 +0100)]
input focus: calculate areas of intersection

12 years agosimplify dmenu_run
Connor Lane Smith [Mon, 17 Oct 2011 09:22:23 +0000 (10:22 +0100)]
simplify dmenu_run

12 years agomerge xim -> default
Connor Lane Smith [Mon, 17 Oct 2011 09:11:48 +0000 (10:11 +0100)]
merge xim -> default

12 years agomerge lsx -> default
Connor Lane Smith [Mon, 17 Oct 2011 09:08:04 +0000 (10:08 +0100)]
merge lsx -> default

12 years agouse ~/.dmenu_cache if no xdg cache
Connor Lane Smith [Mon, 17 Oct 2011 01:12:33 +0000 (02:12 +0100)]
use ~/.dmenu_cache if no xdg cache

12 years agolsx: detect read errors
Connor Lane Smith [Mon, 17 Oct 2011 00:44:07 +0000 (01:44 +0100)]
lsx: detect read errors

12 years agoxim: check for corner cases
Connor Lane Smith [Mon, 17 Oct 2011 00:18:57 +0000 (01:18 +0100)]
xim: check for corner cases

12 years agofix extra warning
Connor Lane Smith [Sun, 16 Oct 2011 17:26:11 +0000 (18:26 +0100)]
fix extra warning

12 years agolsx: return failure on error
Connor Lane Smith [Sun, 16 Oct 2011 17:14:51 +0000 (18:14 +0100)]
lsx: return failure on error

12 years agomerge default -> lsx
Connor Lane Smith [Sun, 16 Oct 2011 17:13:29 +0000 (18:13 +0100)]
merge default -> lsx

12 years agoadd xim support
Troels Henriksen [Sun, 16 Oct 2011 16:21:33 +0000 (17:21 +0100)]
add xim support

12 years agolimit lines to input
Connor Lane Smith [Thu, 13 Oct 2011 19:43:59 +0000 (20:43 +0100)]
limit lines to input

12 years agoinput focus: fix for reparenting wms
Connor Lane Smith [Tue, 4 Oct 2011 20:39:56 +0000 (21:39 +0100)]
input focus: fix for reparenting wms

12 years agofix monitor select when no focus
Connor Lane Smith [Fri, 30 Sep 2011 20:08:37 +0000 (21:08 +0100)]
fix monitor select when no focus

12 years agomerge token -> default
Connor Lane Smith [Mon, 19 Sep 2011 23:11:01 +0000 (00:11 +0100)]
merge token -> default

12 years agotweak match
Connor Lane Smith [Mon, 19 Sep 2011 23:09:20 +0000 (00:09 +0100)]
tweak match

12 years agoupdate manpage
Connor Lane Smith [Mon, 19 Sep 2011 23:06:13 +0000 (00:06 +0100)]
update manpage