Re: [dev] [libsl][patch] drw_rect()
Hi David,
On 2 July 2013 03:24, David Dufberg Tøttrup <david_AT_dufberg.se> wrote:
> On Jun 28 2013, Anselm R Garbe wrote:
>> On 28 June 2013 12:51, David Dufberg Tøttrup <david_AT_dufberg.se> wrote:
>>> Hi! I assume drw_rect()'s intended purpose isn't to only draw the small
>>> squares in the dwm bar. Patch attached.
>>
>> As dwm uses libsl, your patch would break dwm's approach to draw a
>> nonfilled rectangle for floating tags. Thus I cannot accept your patch
>> for libsl.
>>
> Isn't libsl supposed to be general purpose? A dwm specific function in there
> is wierd then.
I'm rather cautious declaring something general purpose. When a
library is designed for the general purpose it'll offer lot's of
functionality that usually isn't used by many users.
In contrast, libsl's main purpose is to *JUST* contain shared code
among the various suckless projects. The drw-abstraction in particular
is primarily designed to provide the feature set required to most
suckless tools (I do question if st would really benefit from this
abstraction, but it seems possible with some effort). Also the
drw-abstraction allows the implementation for different backends, like
pango/cairo/pixman or the default X11/Xft/fc crap, which was the only
reason for this abstraction.
I don't plan to write a X abstraction, as this would add up the
overall code size significantly. I'd rather do a rewrite of dwm for
Mir/Wayland/whatever than designing an abstraction that fits all those
technology and can be implemented with different backends.
However for the sake of drawing I find the libsl/drw abstraction
particularly useful, as this will keep out the drawing and
font-rendering specifics from core dwm/dmenu/... (and hopefully some
day st).
> Or am I missing something here (like, why the w and h args are not used)?
Such things will happen as long as the consolidation of the
drawing/font code among the suckless projects isn't achieved.
Best regards,
Anselm
Received on Sat Jul 20 2013 - 09:21:03 CEST
This archive was generated by hypermail 2.3.0
: Sat Jul 20 2013 - 09:24:06 CEST