X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=glabels2%2Fsrc%2Flabel-line.c;h=70b26cc4b3446a98abdbd60914f39d8e931b397b;hb=7e55e35f41dbbbbb2dcf285fa5fbcc9007628457;hp=b3eae407df7ba7dc72dfe0f51dedc5f79e0f455e;hpb=83898579197af3dbe8fecb57c729770cd7e34694;p=glabels diff --git a/glabels2/src/label-line.c b/glabels2/src/label-line.c index b3eae407..70b26cc4 100644 --- a/glabels2/src/label-line.c +++ b/glabels2/src/label-line.c @@ -1,35 +1,30 @@ -/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */ - /* - * (GLABELS) Label and Business Card Creation program for GNOME - * - * label_line.c: GLabels label line object + * label-line.c + * Copyright (C) 2001-2009 Jim Evins . * - * Copyright (C) 2001-2007 Jim Evins . + * This file is part of gLabels. * - * This program is free software; you can redistribute it and/or modify + * gLabels is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or + * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * - * This program is distributed in the hope that it will be useful, + * gLabels is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * along with gLabels. If not, see . */ #include "label-line.h" -#include -#include -#include +#include #include "debug.h" + /*========================================================*/ /* Private types. */ /*========================================================*/ @@ -39,28 +34,30 @@ struct _glLabelLinePrivate { glColorNode *line_color_node; }; + /*========================================================*/ /* Private globals. */ /*========================================================*/ + /*========================================================*/ /* Private function prototypes. */ /*========================================================*/ -static void gl_label_line_finalize (GObject *object); +static void gl_label_line_finalize (GObject *object); -static void copy (glLabelObject *dst_object, - glLabelObject *src_object); +static void copy (glLabelObject *dst_object, + glLabelObject *src_object); -static void set_line_color (glLabelObject *object, - glColorNode *line_color_node); +static void set_line_color (glLabelObject *object, + glColorNode *line_color_node); -static void set_line_width (glLabelObject *object, - gdouble line_width); +static void set_line_width (glLabelObject *object, + gdouble line_width); -static glColorNode *get_line_color (glLabelObject *object); +static glColorNode *get_line_color (glLabelObject *object); -static gdouble get_line_width (glLabelObject *object); +static gdouble get_line_width (glLabelObject *object); static void draw_object (glLabelObject *object, cairo_t *cr, @@ -73,12 +70,12 @@ static void draw_shadow (glLabelObject *object, glMergeRecord *record); - /*****************************************************************************/ /* Boilerplate object stuff. */ /*****************************************************************************/ G_DEFINE_TYPE (glLabelLine, gl_label_line, GL_TYPE_LABEL_OBJECT); + static void gl_label_line_class_init (glLabelLineClass *class) { @@ -98,6 +95,7 @@ gl_label_line_class_init (glLabelLineClass *class) object_class->finalize = gl_label_line_finalize; } + static void gl_label_line_init (glLabelLine *lline) { @@ -105,6 +103,7 @@ gl_label_line_init (glLabelLine *lline) lline->priv->line_color_node = gl_color_node_new_default (); } + static void gl_label_line_finalize (GObject *object) { @@ -118,6 +117,7 @@ gl_label_line_finalize (GObject *object) G_OBJECT_CLASS (gl_label_line_parent_class)->finalize (object); } + /*****************************************************************************/ /* NEW label "line" object. */ /*****************************************************************************/ @@ -133,6 +133,7 @@ gl_label_line_new (glLabel *label) return G_OBJECT (lline); } + /*****************************************************************************/ /* Copy object contents. */ /*****************************************************************************/ @@ -182,6 +183,7 @@ set_line_color (glLabelObject *object, } } + /*---------------------------------------------------------------------------*/ /* PRIVATE. Set line width method. */ /*---------------------------------------------------------------------------*/ @@ -213,6 +215,7 @@ get_line_width (glLabelObject *object) return lline->priv->line_width; } + /*---------------------------------------------------------------------------*/ /* PRIVATE. Get line width method. */ /*---------------------------------------------------------------------------*/ @@ -226,6 +229,7 @@ get_line_color (glLabelObject *object) return gl_color_node_dup (lline->priv->line_color_node); } + /*****************************************************************************/ /* Draw object method. */ /*****************************************************************************/ @@ -268,6 +272,7 @@ draw_object (glLabelObject *object, gl_debug (DEBUG_LABEL, "END"); } + /*****************************************************************************/ /* Draw shadow method. */ /*****************************************************************************/ @@ -321,3 +326,14 @@ draw_shadow (glLabelObject *object, gl_debug (DEBUG_LABEL, "END"); } + + + +/* + * Local Variables: -- emacs + * mode: C -- emacs + * c-basic-offset: 8 -- emacs + * tab-width: 8 -- emacs + * indent-tabs-mode: nil -- emacs + * End: -- emacs + */