X-Git-Url: https://git.decadent.org.uk/gitweb/?p=ion3.git;a=blobdiff_plain;f=ioncore%2Fgr.c;fp=ioncore%2Fgr.c;h=835c7ca2ad5b87f34ee32080a68a02df7f33d26a;hp=f86479287fd6ef2c84e50ece3ef2384b77657ff8;hb=ae4260bb64817c11f9a7140324cd3e3ba113e297;hpb=de22e45179cb3bafa490294d31d47f361047a30a diff --git a/ioncore/gr.c b/ioncore/gr.c index f864792..835c7ca 100644 --- a/ioncore/gr.c +++ b/ioncore/gr.c @@ -3,10 +3,7 @@ * * Copyright (c) Tuomo Valkonen 1999-2007. * - * Ion is free software; you can redistribute it and/or modify it under - * the terms of the GNU Lesser General Public License as published by - * the Free Software Foundation; either version 2.1 of the License, or - * (at your option) any later version. + * See the included file LICENSE for details. */ #include @@ -98,7 +95,7 @@ static bool gr_do_select_engine(const char *engine) /*EXTL_DOC - * Future requests for ''brushes'' are to be forwarded to the drawing engine + * Future requests for ``brushes'' are to be forwarded to the drawing engine * \var{engine}. If no engine of such name is known, a module with that name * is attempted to be loaded. This function is only intended to be called from * colour scheme etc. configuration files and can not be used to change the @@ -299,7 +296,7 @@ void gr_stylespec_init(GrStyleSpec *spec) } -static bool gr_stylespec_find_(GrStyleSpec *spec, GrAttr a, int *idx_ge) +static bool gr_stylespec_find_(const GrStyleSpec *spec, GrAttr a, int *idx_ge) { bool found=FALSE; uint i; @@ -315,6 +312,15 @@ static bool gr_stylespec_find_(GrStyleSpec *spec, GrAttr a, int *idx_ge) return found; } + +bool gr_stylespec_isset(const GrStyleSpec *spec, GrAttr a) +{ + int idx_ge; + + return gr_stylespec_find_(spec, a, &idx_ge); +} + + bool gr_stylespec_add(GrStyleSpec *spec, GrAttr a, uint score) { static const uint sz=sizeof(GrAttrScore); @@ -632,7 +638,7 @@ void grbrush_unset_attr(GrBrush *brush, GrAttr attr) /*EXTL_DOC - * Read drawing engine configuration file \file{draw.lua}. + * Read drawing engine configuration file \file{look.lua}. */ EXTL_EXPORT_AS(gr, read_config) void gr_read_config()