+2007-10-12 Jim Evins <evins@snaught.com>
+
+ * docs/libglabels/libglabels-decl-list.txt:
+ * docs/libglabels/libglabels-sections.txt:
+ * docs/libglabels/libglabels-undocumented.txt:
+ * docs/libglabels/tmpl/category.sgml:
+ * docs/libglabels/tmpl/enums.sgml:
+ * docs/libglabels/tmpl/libglabels-unused.sgml:
+ * docs/libglabels/tmpl/paper.sgml:
+ * docs/libglabels/tmpl/template-struct.sgml:
+ * libglabels/init.c:
+ * libglabels/template.c:
+ * libglabels/template.h:
+ Another pass at fleshing out the libglabels documentation.
+ * src/cairo-label-path.c:
+ * src/cairo-markup-path.c:
+ * src/label.c:
+ * src/mini-preview-pixbuf.c:
+ * src/print-op.c:
+ * src/print.c:
+ * src/view.c:
+ * src/wdgt-media-select.c:
+ * src/wdgt-mini-preview.c:
+ * src/wdgt-print-copies.c:
+ * src/wdgt-print-merge.c:
+ * src/wdgt-rotate-label.c:
+ Removed lgl_template_get_first_frame() from libglabels API and all references.
+
2007-10-11 Jim Evins <evins@snaught.com>
* configure.in:
Extended checks for deprecated symbols.
lgl_template_get_name_list_all
lgl_template_free_name_list
lgl_template_from_name
-lgl_template_get_first_frame
lgl_template_does_page_size_match
lgl_template_does_category_match
lgl_template_frame_get_size
lgl_paper_new
lgl_paper_dup
lgl_paper_free
+lgl_paper_from_id
+lgl_paper_from_name
+<SUBSECTION List Functions>
lgl_paper_get_id_list
lgl_paper_free_id_list
lgl_paper_get_name_list
lgl_paper_free_name_list
+<SUBSECTION Query Functions>
lgl_paper_is_id_known
lgl_paper_is_id_other
-lgl_paper_from_id
-lgl_paper_from_name
+<SUBSECTION Conversion Functions>
lgl_paper_lookup_id_from_name
lgl_paper_lookup_name_from_id
+<SUBSECTION Debug Functions>
lgl_paper_print_known_papers
</SECTION>
lgl_category_new
lgl_category_dup
lgl_category_free
-lgl_category_get_name_list
-lgl_category_free_name_list
lgl_category_from_name
lgl_category_from_id
+<SUBSECTION List Functions>
+lgl_category_get_name_list
+lgl_category_free_name_list
+<SUBSECTION Conversion Functions>
lgl_category_lookup_id_from_name
lgl_category_lookup_name_from_id
</SECTION>
<FILE>template-struct</FILE>
<INCLUDE>libglabels/template.h</INCLUDE>
lglTemplate
+<SUBSECTION Frame Structure>
lglTemplateFrameShape
lglTemplateFrame
lglTemplateFrameAll
lglTemplateFrameRect
lglTemplateFrameRound
lglTemplateFrameCD
+<SUBSECTION Layout Structure>
lglTemplateLayout
+<SUBSECTION Markup Structure>
lglTemplateMarkupType
lglTemplateMarkup
lglTemplateMarkupMargin
lglTemplateMarkupLine
lglTemplateMarkupCircle
lglTemplateMarkupRect
+<SUBSECTION Origin Structure>
lglTemplateOrigin
-lgl_template_get_first_frame
+<SUBSECTION Template Query Functions>
lgl_template_does_page_size_match
lgl_template_does_category_match
+<SUBSECTION Frame Frame Query Functions>
lgl_template_frame_get_size
lgl_template_frame_get_n_labels
lgl_template_frame_get_origins
lgl_template_get_name_list_unique
lgl_template_get_name_list_all
lgl_template_free_name_list
+<SUBSECTION Locate Template Functions>
lgl_template_from_name
+<SUBSECTION Template Registration Functions>
lgl_template_register
</SECTION>
lgl_template_add_category
lgl_template_add_frame
lgl_template_add_alias
+<SUBSECTION Frame Functions>
lgl_template_frame_rect_new
lgl_template_frame_round_new
lgl_template_frame_cd_new
lgl_template_frame_free
lgl_template_frame_add_layout
lgl_template_frame_add_markup
+<SUBSECTION Layout Functions>
lgl_template_layout_new
lgl_template_layout_dup
lgl_template_layout_free
+<SUBSECTION Markup Functions>
lgl_template_markup_margin_new
lgl_template_markup_line_new
lgl_template_markup_circle_new
<FILE>xml</FILE>
<INCLUDE>libglabels/xml.h</INCLUDE>
LGL_XML_NAME_SPACE
+<SUBSECTION Get Property Functions>
lgl_xml_get_prop_string
lgl_xml_get_prop_i18n_string
lgl_xml_get_prop_double
lgl_xml_get_prop_int
lgl_xml_get_prop_uint
lgl_xml_get_prop_length
+<SUBSECTION Set Property Functions>
lgl_xml_set_prop_string
lgl_xml_set_prop_double
lgl_xml_set_prop_boolean
lgl_xml_set_prop_int
lgl_xml_set_prop_uint_hex
lgl_xml_set_prop_length
+<SUBSECTION Misc Functions>
lgl_xml_is_node
lgl_xml_get_node_content
+<SUBSECTION Configuration Functions>
lgl_xml_set_default_units
</SECTION>
-85% symbol docs coverage.
-111 symbols documented.
+99% symbol docs coverage.
+128 symbols documented.
0 symbols incomplete.
-19 not documented.
+1 not documented.
LGL_XML_NAME_SPACE
-lglCategory
-lglPaper
-lglTemplate
-lglTemplateFrame
-lglTemplateFrameAll
-lglTemplateFrameCD
-lglTemplateFrameRect
-lglTemplateFrameRound
-lglTemplateFrameShape
-lglTemplateLayout
-lglTemplateMarkup
-lglTemplateMarkupCircle
-lglTemplateMarkupLine
-lglTemplateMarkupMargin
-lglTemplateMarkupRect
-lglTemplateMarkupType
-lglTemplateOrigin
-lglUnitsType
<!-- ##### STRUCT lglCategory ##### -->
<para>
-
+This structure defines a category.
</para>
-@id:
-@name:
+@id: Category ID.
+@name: Localized category name.
<!-- ##### FUNCTION lgl_category_new ##### -->
<para>
@category:
-<!-- ##### FUNCTION lgl_category_get_name_list ##### -->
+<!-- ##### FUNCTION lgl_category_from_name ##### -->
<para>
</para>
+@name:
@Returns:
-<!-- ##### FUNCTION lgl_category_free_name_list ##### -->
+<!-- ##### FUNCTION lgl_category_from_id ##### -->
<para>
</para>
-@names:
+@id:
+@Returns:
-<!-- ##### FUNCTION lgl_category_from_name ##### -->
+<!-- ##### FUNCTION lgl_category_get_name_list ##### -->
<para>
</para>
-@name:
@Returns:
-<!-- ##### FUNCTION lgl_category_from_id ##### -->
+<!-- ##### FUNCTION lgl_category_free_name_list ##### -->
<para>
</para>
-@id:
-@Returns:
+@names:
<!-- ##### FUNCTION lgl_category_lookup_id_from_name ##### -->
<!-- ##### ENUM lglUnitsType ##### -->
<para>
-
+This enumeration defines a set of units of distance supported by the libglabels XML distance
+attributes.
</para>
-@LGL_UNITS_POINT:
-@LGL_UNITS_INCH:
-@LGL_UNITS_MM:
-@LGL_UNITS_CM:
-@LGL_UNITS_PICA:
-@LGL_UNITS_FIRST:
-@LGL_UNITS_LAST:
+@LGL_UNITS_POINT: Points. Encoded as "pt" in XML distance attributes.
+@LGL_UNITS_INCH: Inches. Encoded as "in" in XML distance attributes.
+@LGL_UNITS_MM: Millmeters. Encoded as "mm" in XML distance attributes.
+@LGL_UNITS_CM: Centimeters. Encoded as "cm" in XML distance attributes.
+@LGL_UNITS_PICA: Picas. Encoded as "pc" in XML distance attributes.
+@LGL_UNITS_FIRST: First enumeration. Used for generic iteration through supported units..
+@LGL_UNITS_LAST: Last enumeration. Used for generic iteration through supported units.
@frame:
@markup:
+<!-- ##### FUNCTION lgl_template_get_first_frame ##### -->
+<para>
+
+</para>
+
+@template:
+@Returns:
+
<!-- ##### FUNCTION lgl_template_init ##### -->
<para>
<!-- ##### STRUCT lglPaper ##### -->
<para>
-
+This structure defines a paper (page) size.
</para>
-@id:
-@name:
-@width:
-@height:
+@id: Paper size ID.
+@name: Localized paper size name.
+@width: Width of paper in points.
+@height: Height of paper in points.
<!-- ##### FUNCTION lgl_paper_new ##### -->
<para>
@paper:
-<!-- ##### FUNCTION lgl_paper_get_id_list ##### -->
+<!-- ##### FUNCTION lgl_paper_from_id ##### -->
<para>
</para>
+@id:
@Returns:
-<!-- ##### FUNCTION lgl_paper_free_id_list ##### -->
+<!-- ##### FUNCTION lgl_paper_from_name ##### -->
<para>
</para>
-@ids:
+@name:
+@Returns:
-<!-- ##### FUNCTION lgl_paper_get_name_list ##### -->
+<!-- ##### FUNCTION lgl_paper_get_id_list ##### -->
<para>
</para>
@Returns:
-<!-- ##### FUNCTION lgl_paper_free_name_list ##### -->
+<!-- ##### FUNCTION lgl_paper_free_id_list ##### -->
<para>
</para>
-@names:
+@ids:
-<!-- ##### FUNCTION lgl_paper_is_id_known ##### -->
+<!-- ##### FUNCTION lgl_paper_get_name_list ##### -->
<para>
</para>
-@id:
@Returns:
-<!-- ##### FUNCTION lgl_paper_is_id_other ##### -->
+<!-- ##### FUNCTION lgl_paper_free_name_list ##### -->
<para>
</para>
-@id:
-@Returns:
+@names:
-<!-- ##### FUNCTION lgl_paper_from_id ##### -->
+<!-- ##### FUNCTION lgl_paper_is_id_known ##### -->
<para>
</para>
@Returns:
-<!-- ##### FUNCTION lgl_paper_from_name ##### -->
+<!-- ##### FUNCTION lgl_paper_is_id_other ##### -->
<para>
</para>
-@name:
+@id:
@Returns:
<!-- ##### SECTION Long_Description ##### -->
<para>
This section describes a set of structures that represent a template in memory. It also
-describes functions for querying such structures.
+describes functions to help interpret these structures.
</para>
<!-- ##### SECTION See_Also ##### -->
<!-- ##### STRUCT lglTemplate ##### -->
<para>
-
+This is the main structure of a libglabels template. A template represents a single sheet
+of peel-off labels or cards.
</para>
-@name:
-@description:
-@page_size:
-@page_width:
-@page_height:
-@categories:
-@frames:
-@aliases:
+@name: The primary name of the template. Usually a manufacturer followed by a part number.
+@description: A description of the template. E.g. "Mailing labels."
+@page_size: A page size ID. E.g. "US-Letter" or "A4."
+@page_width: Page width in points. Used only if page_size is "Other."
+@page_height: Page height in points. Used only if page_size is "Other."
+@categories: A list of category IDs associated with this template.
+@frames: A list of (#lglTemplateFrame *) structures. GLabels currently only supports one frame
+per template -- future versions may support multiple frames per template.
+@aliases: A list of alternate names for this template. Often a single template can be used for
+multiple products.
<!-- ##### ENUM lglTemplateFrameShape ##### -->
<para>
-
+This enumeration defines frame types that are supported by libglabels
</para>
-@LGL_TEMPLATE_FRAME_SHAPE_RECT:
-@LGL_TEMPLATE_FRAME_SHAPE_ROUND:
-@LGL_TEMPLATE_FRAME_SHAPE_CD:
+@LGL_TEMPLATE_FRAME_SHAPE_RECT: A rectangular frame. (May have rounded corners.)
+@LGL_TEMPLATE_FRAME_SHAPE_ROUND: A round frame.
+@LGL_TEMPLATE_FRAME_SHAPE_CD: A CD or DVD frame. (Includes credit-card style CDs.)
<!-- ##### UNION lglTemplateFrame ##### -->
<para>
-
+A union of all possible frame structures. The type of structure is indicated by the shape
+member, which overlays the first field of all other member structures.
</para>
<!-- ##### STRUCT lglTemplateFrameAll ##### -->
<para>
-
+This structure is composed of a set of fields common to all frame structures. All frame types
+can be cast to this structure.
</para>
-@shape:
-@id:
-@layouts:
-@markups:
+@shape: The shape of the frame.
+@id: Reserved for future use. Should always be zero.
+@layouts: A list of (#lglTemplateLayout *) structures. Typically a frame will have a single
+layout, representing a simple grid of labels or cards. If the layout of labels or cards is
+more complex, multiple (#lglTemplateLayout *) structures may be needed.
+@markups: A list of (#lglTemplateMarkup *) structures, which represent non-printing markup lines.
<!-- ##### STRUCT lglTemplateFrameRect ##### -->
<para>
-
+This structure defines the frame for a rectangular label or card.
</para>
-@shape:
-@id:
-@layouts:
-@markups:
-@w:
-@h:
-@r:
-@x_waste:
-@y_waste:
+@shape: Common field. Always #LGL_TEMPLATE_FRAME_SHAPE_RECT for #lglTemplateFrameRect.
+@id: Common field. See #lglTemplateFrameAll.
+@layouts: Common field. See #lglTemplateFrameAll.
+@markups: Common field. See #lglTemplateFrameAll.
+@w: Width of label or card in points.
+@h: Height of label or card in points.
+@r: Radius of corners in points.
+@x_waste: Amount of horizontal over-print to allow in points.
+@y_waste: Amount of vertical over-print to allow in points.
<!-- ##### STRUCT lglTemplateFrameRound ##### -->
<para>
-
+This structure defines the frame for a round label or card.
</para>
-@shape:
-@id:
-@layouts:
-@markups:
-@r:
-@waste:
+@shape: Common field. Always #LGL_TEMPLATE_FRAME_SHAPE_ROUND for #lglTemplateFrameRound.
+@id: Common field. See #lglTemplateFrameAll.
+@layouts: Common field. See #lglTemplateFrameAll.
+@markups: Common field. See #lglTemplateFrameAll.
+@r: Radius of label or card in points.
+@waste: Amount of over-print to allow in points.
<!-- ##### STRUCT lglTemplateFrameCD ##### -->
<para>
-
+This structure defines the frame for a CD or DVD label. This structure also supports
+credit-card CD labels.
</para>
-@shape:
-@id:
-@layouts:
-@markups:
-@r1:
-@r2:
-@w:
-@h:
-@waste:
+@shape: Common field. Always #LGL_TEMPLATE_FRAME_SHAPE_CD for #lglTemplateFrameCD.
+@id: Common field. See #lglTemplateFrameAll.
+@layouts: Common field. See #lglTemplateFrameAll.
+@markups: Common field. See #lglTemplateFrameAll.
+@r1: Outer radius of label in points.
+@r2: Radius of center hole in points.
+@w: Clip width in points. Used for credit-card CD labels. This field is ignored if zero.
+@h: Clip height in points. Used for credit-card CD labels. This field is ignored if zero.
+@waste: Amount of over-print to allow in points.
<!-- ##### STRUCT lglTemplateLayout ##### -->
<para>
-
+This structure defines a simple grid layout of labels or cards.
</para>
-@nx:
-@ny:
-@x0:
-@y0:
-@dx:
-@dy:
+@nx: Number of labels or cards across in the grid (horizontal).
+@ny: Number of labels or cards down in the grid (vertical).
+@x0: Distance (in points) from the left edge of page to the left edge of the left column of
+cards or labels in the layout.
+@y0: Distance (in points) from the top edge of page to the top edge of the top row of
+cards or labels in the layout.
+@dx: Horizontal pitch of grid in points. This is the distance from left edge to left edge
+(not the gap between labels or cards).
+@dy: Vertical pitch of grid in points. This is the distance from top edge to top edge
+(not the gap between labels or cards).
<!-- ##### ENUM lglTemplateMarkupType ##### -->
<para>
-
+This enumeration defines markup types that are supported by libglabels
</para>
-@LGL_TEMPLATE_MARKUP_MARGIN:
-@LGL_TEMPLATE_MARKUP_LINE:
-@LGL_TEMPLATE_MARKUP_CIRCLE:
-@LGL_TEMPLATE_MARKUP_RECT:
+@LGL_TEMPLATE_MARKUP_MARGIN: A margin line around perimeter of label or card.
+@LGL_TEMPLATE_MARKUP_LINE: A simple line segment.
+@LGL_TEMPLATE_MARKUP_CIRCLE: A circle.
+@LGL_TEMPLATE_MARKUP_RECT: A rectangle. Possibly with rounded corners.
<!-- ##### UNION lglTemplateMarkup ##### -->
<para>
-
+A union of all possible markup structures. The type of structure is indicated by the type
+member, which overlays the first field of all other member structures.
</para>
<!-- ##### STRUCT lglTemplateMarkupMargin ##### -->
<para>
-
+This structure defines a simple margin markup around the perimeter of a label or card.
</para>
-@type:
-@size:
+@type: Common field. Always #LGL_TEMPLATE_MARKUP_MARGIN for #lglTemplateMarkupMargin.
+@size: Distance of margin from edge of label or card.
<!-- ##### STRUCT lglTemplateMarkupLine ##### -->
<para>
-
+This structure defines a simple line segment markup.
</para>
-@type:
-@x1:
-@y1:
-@x2:
-@y2:
+@type: Common field. Always #LGL_TEMPLATE_MARKUP_LINE for #lglTemplateMarkupLine.
+@x1: Distance (in points) of first endpoint from left edge of label or card.
+@y1: Distance (in points) of first endpoint from top edge of label or card.
+@x2: Distance (in points) of second endpoint from left edge of label or card.
+@y2: Distance (in points) of second endpoint from top edge of label or card.
<!-- ##### STRUCT lglTemplateMarkupCircle ##### -->
<para>
-
+This structure defines a simple circle markup.
</para>
-@type:
-@x0:
-@y0:
-@r:
+@type: Common field. Always #LGL_TEMPLATE_MARKUP_CIRCLE for #lglTemplateMarkupCircle.
+@x0: Distance (in points) of vertex from left edge of label or card.
+@y0: Distance (in points) of vertex from top edge of label or card.
+@r: Radius of circle in points.
<!-- ##### STRUCT lglTemplateMarkupRect ##### -->
<para>
-
+This structure defines a simple rectangle markup. The rectangle can have rounded corners.
</para>
-@type:
-@x1:
-@y1:
-@w:
-@h:
-@r:
+@type: Common field. Always #LGL_TEMPLATE_MARKUP_RECT for #lglTemplateMarkupRect.
+@x1: Distance (in points) of left edge of markup from left edge of label or card.
+@y1: Distance (in points) of top edge of markup from top edge of label or card.
+@w: Width of rectangle in points.
+@h: Height of rectangle in points.
+@r: Radius of corners in points. Should be zero for sharp corners.
<!-- ##### STRUCT lglTemplateOrigin ##### -->
<para>
-
+This structure represents the cartesian coordinates of the origin of a label or card on the page.
+The orign is the upper left corner of the extent of the label or card. These coordinates are
+relative to the upper left corner of the page.
</para>
-@x:
-@y:
-
-<!-- ##### FUNCTION lgl_template_get_first_frame ##### -->
-<para>
-
-</para>
-
-@template:
-@Returns:
-
+@x: Distance in points from top edge of page.
+@y: Distance in points from left edge of page.
<!-- ##### FUNCTION lgl_template_does_page_size_match ##### -->
<para>
/**
* lgl_init:
*
- * Initialize all libglabels subsystems. An application should call lgl_init() once
- * before calling any other libglabels functions.
+ * Initialize all libglabels subsystems. It is not necessary for an application to call
+ * lgl_init(), because libglabels will initialize on demand. An application programmer may
+ * choose to call lgl_init() at startup to minimize the impact of the first libglabels call
+ * on GUI response time.
*
- * This function reads in all files containing paper definitions, category definitions,
- * and templates to build its template data base. This function will search both system
- * and user template directories for these files.
+ * This function initializes its paper definitions, category definitions, and its template
+ * database.. It will search both system and user template directories to locate
+ * this data.
*/
void
lgl_init (void)
* @page_size: If non NULL, limit results to given page size.
* @category: If non NULL, limit results to given template category.
*
- * Get a list of valid names and aliases of unique templates in the template database.
+ * Get a list of all valid names and aliases of templates in the template database.
* Results can be filtered by page size and/or template category. A list of valid page
* sizes can be obtained using lgl_paper_get_id_list(). A list of valid template
* categories can be obtained using lgl_category_get_id_list().
return lgl_template_dup ((lglTemplate *) templates->data);
}
-/**
- * lgl_template_get_first_frame:
- * @template: #lglTemplate structure to query
- *
- * Lookup first #lglTemplateFrame in the given #lglTemplate. The returned
- * value is simply a pointer to the given frame within the template and should
- * not be freed.
- *
- * Note: glabels currently only supports a single frame per template.
- *
- * Returns: pointer to #lglTemplateFrame structure.
- *
- */
-const lglTemplateFrame *
-lgl_template_get_first_frame (const lglTemplate *template)
-{
- g_return_val_if_fail (template, NULL);
-
- return (lglTemplateFrame *)template->frames->data;
-}
-
/**
* lgl_template_frame_get_size:
* @frame: #lglTemplateFrame structure to query
*
* Get an array of label origins for the given frame. These origins represent the
* upper left hand corner of each label on a page corresponding to the given frame.
+ * The origins will be ordered geometrically left to right and then top to bottom.
* The array should be freed using g_free().
*
* Returns: A newly allocated array of #lglTemplateOrigin structures.
/*
* Template query functions
*/
-const lglTemplateFrame *lgl_template_get_first_frame (const lglTemplate *template);
-
gboolean lgl_template_does_page_size_match (const lglTemplate *template,
const gchar *page_size);
gl_debug (DEBUG_PATH, "START");
- frame = lgl_template_get_first_frame (template);
+ frame = (lglTemplateFrame *)template->frames->data;
switch (frame->shape) {
gl_debug (DEBUG_PATH, "START");
- frame = lgl_template_get_first_frame (template);
+ frame = (lglTemplateFrame *)template->frames->data;
r = frame->rect.r;
x_waste = 0.0;
gl_debug (DEBUG_PATH, "START");
- frame = lgl_template_get_first_frame (template);
+ frame = (lglTemplateFrame *)template->frames->data;
if (rotate_flag)
{
gl_debug (DEBUG_PATH, "START");
- frame = lgl_template_get_first_frame (template);
+ frame = (lglTemplateFrame *)template->frames->data;
if (rotate_flag)
{
gl_debug (DEBUG_PATH, "START");
- frame = lgl_template_get_first_frame (label->template);
+ frame = (lglTemplateFrame *)label->template->frames->data;
switch (frame->shape) {
gl_debug (DEBUG_PATH, "START");
- frame = lgl_template_get_first_frame (label->template);
+ frame = (lglTemplateFrame *)label->template->frames->data;
m = markup->margin.size;
gl_debug (DEBUG_PATH, "START");
- frame = lgl_template_get_first_frame (label->template);
+ frame = (lglTemplateFrame *)label->template->frames->data;
r = frame->round.r;
m = markup->margin.size;
gl_debug (DEBUG_PATH, "START");
- frame = lgl_template_get_first_frame (label->template);
+ frame = (lglTemplateFrame *)label->template->frames->data;
gl_label_get_size (label, &w, &h);
xc = w/2.0;
*w = *h = 0;
return;
}
- frame = lgl_template_get_first_frame (template);
+ frame = (lglTemplateFrame *)template->frames->data;
if (!label->rotate_flag) {
lgl_template_frame_get_size (frame, w, h);
cairo_set_line_width (cr, LABEL_OUTLINE_WIDTH_PIXELS/scale);
- frame = lgl_template_get_first_frame (template);
+ frame = (lglTemplateFrame *)template->frames->data;
n_labels = lgl_template_frame_get_n_labels (frame);
origins = lgl_template_frame_get_origins (frame);
op->priv->label = label;
op->priv->force_outline_flag = FALSE;
- frame = lgl_template_get_first_frame (label->template);
+ frame = (lglTemplateFrame *)label->template->frames->data;
op->priv->n_sheets = 1;
op->priv->first = 1;
merge = gl_label_get_merge (label);
- frame = lgl_template_get_first_frame (label->template);
+ frame = (lglTemplateFrame *)label->template->frames->data;
if (merge == NULL)
{
op->priv->merge_flag = FALSE;
pi = print_info_new (cr, label);
- frame = lgl_template_get_first_frame (pi->template);
+ frame = (lglTemplateFrame *)pi->template->frames->data;
origins = lgl_template_frame_get_origins (frame);
if (crop_marks_flag) {
record_list = gl_merge_get_record_list (merge);
pi = print_info_new (cr, label);
- frame = lgl_template_get_first_frame (pi->template);
+ frame = (lglTemplateFrame *)pi->template->frames->data;
n_labels_per_page = lgl_template_frame_get_n_labels (frame);
origins = lgl_template_frame_get_origins (frame);
record_list = gl_merge_get_record_list (merge);
pi = print_info_new (cr, label);
- frame = lgl_template_get_first_frame (pi->template);
+ frame = (lglTemplateFrame *)pi->template->frames->data;
n_labels_per_page = lgl_template_frame_get_n_labels (frame);
origins = lgl_template_frame_get_origins (frame);
gl_debug (DEBUG_PRINT, "START");
- frame = lgl_template_get_first_frame (pi->template);
+ frame = (lglTemplateFrame *)pi->template->frames->data;
lgl_template_frame_get_size (frame, &w, &h);
gl_debug (DEBUG_PRINT, "START");
- frame = lgl_template_get_first_frame (pi->template);
+ frame = (lglTemplateFrame *)pi->template->frames->data;
gl_label_get_size (label, &width, &height);
if (view->grid_visible)
{
- frame = lgl_template_get_first_frame (view->label->template);
+ frame = (lglTemplateFrame *)view->label->template->frames->data;
gl_label_get_size (view->label, &w, &h);
{
label = view->label;
- frame = lgl_template_get_first_frame (label->template);
+ frame = (lglTemplateFrame *)view->label->template->frames->data;
cairo_save (cr);
gint n_labels;
gchar *string;
- frame = lgl_template_get_first_frame (template);
+ frame = (lglTemplateFrame *)template->frames->data;
n_labels = lgl_template_frame_get_n_labels (frame);
units_string = gl_prefs_get_units_string ();
units_per_point = gl_prefs_get_units_per_point ();
- frame = lgl_template_get_first_frame (template);
+ frame = (lglTemplateFrame *)template->frames->data;
switch (frame->shape) {
case LGL_TEMPLATE_FRAME_SHAPE_RECT:
gl_debug (DEBUG_MINI_PREVIEW, "START");
- frame = lgl_template_get_first_frame (template);
+ frame = (lglTemplateFrame *)template->frames->data;
/*
* Set template
gl_debug (DEBUG_MINI_PREVIEW, "START");
- frame = lgl_template_get_first_frame (template);
+ frame = (lglTemplateFrame *)template->frames->data;
n_labels = lgl_template_frame_get_n_labels (frame);
origins = lgl_template_frame_get_origins (frame);
whbox = GTK_WIDGET (copies);
- frame = lgl_template_get_first_frame (label->template);
+ frame = (lglTemplateFrame *)label->template->frames->data;
copies->labels_per_sheet = lgl_template_frame_get_n_labels (frame);
whbox = GTK_WIDGET (merge);
- frame = lgl_template_get_first_frame (label->template);
+ frame = (lglTemplateFrame *)label->template->frames->data;
merge->labels_per_sheet = lgl_template_frame_get_n_labels (frame);
return;
}
- frame = lgl_template_get_first_frame (template);
+ frame = (lglTemplateFrame *)template->frames->data;
if (rotate_flag)
{
else
{
template = lgl_template_from_name (name);
- frame = lgl_template_get_first_frame (template);
+ frame = (lglTemplateFrame *)template->frames->data;
rotate_label->priv->template = template;
lgl_template_frame_get_size (frame, &raw_w, &raw_h);