libDXF 0.0.1
A library with DXF related functions written in C.
Functions

ltype.c File Reference

Functions for a DXF ltype symbol table entry (LTYPE). More...

#include "ltype.h"
Include dependency graph for ltype.c:

Go to the source code of this file.

Functions

DxfLTypedxf_ltype_new ()
 Allocate memory for a DxfLType.
DxfLTypedxf_ltype_init (DxfLType *ltype)
 Allocate memory and initialize data fields for a DXF LTYPE symbol table entry.
DxfLTypedxf_ltype_read (DxfFile *fp, DxfLType *ltype)
 Read data from a DXF file into a DXF LTYPE symbol table entry.
int dxf_ltype_write (DxfFile *fp, DxfLType *ltype)
 Write DXF output to a file for a LTYPE symbol table entry.
int dxf_ltype_free (DxfLType *ltype)
 Free the allocated memory for a DXF LTYPE and all it's data fields.
void dxf_ltype_free_chain (DxfLType *ltypes)
 Free the allocated memory for a chain of DXF LTYPE symbol table entries and all their data fields.
int dxf_ltype_get_id_code (DxfLType *ltype)
 Get the ID code from a DXF LTYPE entity.
DxfLTypedxf_ltype_set_id_code (DxfLType *ltype, int id_code)
 Set the ID code for a DXF LTYPE entity.
char * dxf_ltype_get_linetype_name (DxfLType *ltype)
 Get the linetype_name from a DXF LTYPE entity.
DxfLTypedxf_ltype_set_linetype_name (DxfLType *ltype, char *linetype_name)
 Set the linetype_name for a DXF LTYPE entity.
char * dxf_ltype_get_description (DxfLType *ltype)
 Get the description from a DXF LTYPE entity.
DxfLTypedxf_ltype_set_description (DxfLType *ltype, char *description)
 Set the description for a DXF LTYPE entity.
char * dxf_ltype_get_complex_text_string (DxfLType *ltype, int i)
 Get the complex_text_string indexed by i from a DXF LTYPE entity.
DxfLTypedxf_ltype_set_complex_text_string (DxfLType *ltype, int i, char *complex_text_string)
 Set the complex_text_string for index i for a DXF LTYPE entity.
double dxf_ltype_get_total_pattern_length (DxfLType *ltype)
 Get the total_pattern_length from a DXF LTYPE entity.
DxfLTypedxf_ltype_set_total_pattern_length (DxfLType *ltype, double total_pattern_length)
 Set the total_pattern_length for a DXF LTYPE entity.
double dxf_ltype_get_complex_x_offset (DxfLType *ltype, int i)
 Get the complex_x_offset indexed by i from a DXF LTYPE entity.
DxfLTypedxf_ltype_set_complex_x_offset (DxfLType *ltype, int i, double complex_x_offset)
 Set the complex_x_offset for index i for a DXF LTYPE entity.
double dxf_ltype_get_complex_y_offset (DxfLType *ltype, int i)
 Get the complex_y_offset indexed by i from a DXF LTYPE entity.
DxfLTypedxf_ltype_set_complex_y_offset (DxfLType *ltype, int i, double complex_y_offset)
 Set the complex_y_offset for index i for a DXF LTYPE entity.
double dxf_ltype_get_complex_scale (DxfLType *ltype, int i)
 Get the complex_scale indexed by i from a DXF LTYPE entity.
DxfLTypedxf_ltype_set_complex_scale (DxfLType *ltype, int i, double complex_scale)
 Set the complex_scale for index i for a DXF LTYPE entity.
double dxf_ltype_get_dash_length (DxfLType *ltype, int i)
 Get the dash_length indexed by i from a DXF LTYPE entity.
DxfLTypedxf_ltype_set_dash_length (DxfLType *ltype, int i, double dash_length)
 Set the dash_length for index i for a DXF LTYPE entity.
double dxf_ltype_get_complex_rotation (DxfLType *ltype, int i)
 Get the complex_rotation indexed by i from a DXF LTYPE entity.
DxfLTypedxf_ltype_set_complex_rotation (DxfLType *ltype, int i, double complex_rotation)
 Set the complex_rotation for index i for a DXF LTYPE entity.
int dxf_ltype_get_flag (DxfLType *ltype)
 Get the flag from a DXF LTYPE entity.
DxfLTypedxf_ltype_set_flag (DxfLType *ltype, int flag)
 Set the flag for a DXF LTYPE entity.
int dxf_ltype_is_xreferenced (DxfLType *ltype)
 Test if ltype is externally dependent on an xref.
int dxf_ltype_is_xresolved (DxfLType *ltype)
 Test if ltype is externally dependent on a xref and has been successfully resolved.
int dxf_ltype_is_referenced (DxfLType *ltype)
 Test if ltype is internally referenced by an entity.
int dxf_ltype_get_alignment (DxfLType *ltype)
 Get the alignment from a DXF LTYPE entity.
DxfLTypedxf_ltype_set_alignment (DxfLType *ltype, int alignment)
 Set the alignment for a DXF LTYPE entity.
int dxf_ltype_get_number_of_linetype_elements (DxfLType *ltype)
 Get the number_of_linetype_elements from a DXF LTYPE entity.
DxfLTypedxf_ltype_set_number_of_linetype_elements (DxfLType *ltype, int number_of_linetype_elements)
 Set the number_of_linetype_elements for a DXF LTYPE entity.
int dxf_ltype_get_complex_element (DxfLType *ltype, int i)
 Get the complex_element indexed by i from a DXF LTYPE entity.
DxfLTypedxf_ltype_set_complex_element (DxfLType *ltype, int i, int complex_element)
 Set the complex_element for index i for a DXF LTYPE entity.
int dxf_ltype_get_complex_shape_number (DxfLType *ltype, int i)
 Get the complex_shape_number indexed by i from a DXF LTYPE entity.
DxfLTypedxf_ltype_set_complex_shape_number (DxfLType *ltype, int i, int complex_shape_number)
 Set the complex_shape_number for index i for a DXF LTYPE entity.
char * dxf_ltype_get_dictionary_owner_soft (DxfLType *ltype)
 Get the soft pointer to the dictionary owner from a DXF LTYPE entity.
DxfLTypedxf_ltype_set_dictionary_owner_soft (DxfLType *ltype, char *dictionary_owner_soft)
 Set the pointer to the dictionary_owner_soft for a DXF LTYPE entity.
char * dxf_ltype_get_complex_style_pointer (DxfLType *ltype, int i)
 Get the complex_style_pointer indexed by i from a DXF LTYPE entity.
DxfLTypedxf_ltype_set_complex_style_pointer (DxfLType *ltype, int i, char *complex_style_pointer)
 Set the complex_style_pointer for index i for a DXF LTYPE entity.
char * dxf_ltype_get_dictionary_owner_hard (DxfLType *ltype)
 Get the hard pointer to the dictionary owner from a DXF LTYPE entity.
DxfLTypedxf_ltype_set_dictionary_owner_hard (DxfLType *ltype, char *dictionary_owner_hard)
 Set the pointer to the dictionary_owner_hard for a DXF LTYPE entity.
DxfLTypedxf_ltype_get_next (DxfLType *ltype)
 Get the pointer to the next LTYPE entity from a DXF LTYPE entity.
DxfLTypedxf_ltype_set_next (DxfLType *ltype, DxfLType *next)
 Set the pointer to the next LTYPE for a DXF LTYPE entity.
DxfLTypedxf_ltype_get_last (DxfLType *ltype)
 Get the pointer to the last LTYPE entity from a linked list of DXF LTYPE entities.

Detailed Description

Functions for a DXF ltype symbol table entry (LTYPE).

Author:
Copyright (C) 2008, 2012, 2014, 2015, 2017 by Bert Timmerman <bert.timmerman@xs4all.nl>.
Version:
According to DXF R10.
According to DXF R11.
According to DXF R12.
According to DXF R13.
According to DXF R14.

Copyright Notices.


This program 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 (at your option) any later version.

This program 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:
Free Software Foundation, Inc.,
59 Temple Place,
Suite 330,
Boston,
MA 02111 USA.

Drawing eXchange Format (DXF) is a defacto industry standard for the exchange of drawing files between various Computer Aided Drafting programs.
DXF is an industry standard designed by Autodesk(TM).
For more details see http://www.autodesk.com .


Definition in file ltype.c.


Function Documentation

DxfLType* dxf_ltype_new ( )

Allocate memory for a DxfLType.

Fill the memory contents with zeros.

Definition at line 51 of file ltype.c.

References _, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

Referenced by dxf_ltype_init(), and dxf_ltype_read().

DxfLType* dxf_ltype_init ( DxfLType ltype)
DxfLType* dxf_ltype_read ( DxfFile fp,
DxfLType ltype 
)

Read data from a DXF file into a DXF LTYPE symbol table entry.

The last line read from file contained the string "LTYPE".
Now follows some data for the LTYPE, to be terminated with a " 0" string announcing the following table record, or the end of the TABLE section marker ENDTAB.
While parsing the DXF file store data in ltype.

Returns:
a pointer to ltype.

Todo:
We are assuming that 49 is the first group code that is encountered for each element in the linetype definition.
This assumption breaks the "rule" of parsing the dxf file regardless the order in which group codes appear within an entity.

Parameters:
fpDXF file pointer to an input file (or device).
ltypea pointer to the DXF LTYPE symbol table entry.

Definition at line 155 of file ltype.c.

References _, dxf_ltype_struct::alignment, dxf_ltype_struct::complex_element, dxf_ltype_struct::complex_rotation, dxf_ltype_struct::complex_scale, dxf_ltype_struct::complex_shape_number, dxf_ltype_struct::complex_style_pointer, dxf_ltype_struct::complex_text_string, dxf_ltype_struct::complex_x_offset, dxf_ltype_struct::complex_y_offset, dxf_ltype_struct::dash_length, dxf_ltype_struct::description, dxf_ltype_struct::dictionary_owner_hard, dxf_ltype_struct::dictionary_owner_soft, DXF_DEBUG_BEGIN, DXF_DEBUG_END, dxf_ltype_init(), dxf_ltype_new(), dxf_file_struct::filename, dxf_ltype_struct::flag, dxf_file_struct::fp, dxf_ltype_struct::id_code, dxf_file_struct::line_number, dxf_ltype_struct::linetype_name, dxf_ltype_struct::number_of_linetype_elements, and dxf_ltype_struct::total_pattern_length.

Here is the call graph for this function:

int dxf_ltype_write ( DxfFile fp,
DxfLType ltype 
)

Write DXF output to a file for a LTYPE symbol table entry.

Returns:
EXIT_SUCCESS when done, or EXIT_FAILURE when an error occurred.

Todo:
for version R14.
Implementing the start of application-defined group "{application_name", with Group code 102.
For example: "{ACAD_REACTORS" indicates the start of the AutoCAD persistent reactors group.

application-defined codes: Group codes and values within the 102 groups are application defined (optional).

End of group, "}" (optional), with Group code 102.

Parameters:
fpDXF file pointer to an output file (or device).
ltypea pointer to the DXF LTYPE symbol table entry.

Definition at line 379 of file ltype.c.

References _, dxf_file_struct::acad_version_number, AutoCAD_14, dxf_ltype_struct::description, DXF_DEBUG_BEGIN, DXF_DEBUG_END, dxf_ltype_get_alignment(), dxf_ltype_get_complex_element(), dxf_ltype_get_complex_rotation(), dxf_ltype_get_complex_scale(), dxf_ltype_get_complex_shape_number(), dxf_ltype_get_complex_style_pointer(), dxf_ltype_get_complex_text_string(), dxf_ltype_get_complex_x_offset(), dxf_ltype_get_complex_y_offset(), dxf_ltype_get_dash_length(), dxf_ltype_get_description(), dxf_ltype_get_dictionary_owner_hard(), dxf_ltype_get_dictionary_owner_soft(), dxf_ltype_get_flag(), dxf_ltype_get_id_code(), dxf_ltype_get_linetype_name(), dxf_ltype_get_number_of_linetype_elements(), dxf_ltype_get_total_pattern_length(), dxf_file_struct::fp, and dxf_ltype_struct::linetype_name.

Here is the call graph for this function:

int dxf_ltype_free ( DxfLType ltype)

Free the allocated memory for a DXF LTYPE and all it's data fields.

Returns:
EXIT_SUCCESS when done, or EXIT_FAILURE when an error occurred.
Parameters:
ltypea pointer to the memory occupied by the DXF LTYPE symbol table entry.

Definition at line 567 of file ltype.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, dxf_ltype_get_complex_style_pointer(), dxf_ltype_get_complex_text_string(), dxf_ltype_get_description(), dxf_ltype_get_dictionary_owner_hard(), dxf_ltype_get_dictionary_owner_soft(), dxf_ltype_get_linetype_name(), DXF_MAX_NUMBER_OF_DASH_LENGTH_ITEMS, and dxf_ltype_struct::next.

Referenced by dxf_ltype_free_chain().

Here is the call graph for this function:

void dxf_ltype_free_chain ( DxfLType ltypes)

Free the allocated memory for a chain of DXF LTYPE symbol table entries and all their data fields.

Parameters:
ltypesa pointer to the chain of DXF LTYPE symbol table entries.

Definition at line 617 of file ltype.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, dxf_ltype_free(), and dxf_ltype_struct::next.

Here is the call graph for this function:

int dxf_ltype_get_id_code ( DxfLType ltype)

Get the ID code from a DXF LTYPE entity.

Returns:
ID code.
Parameters:
ltypea pointer to a DXF LTYPE entity.

Definition at line 651 of file ltype.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ltype_struct::id_code.

Referenced by dxf_ltype_write().

DxfLType* dxf_ltype_set_id_code ( DxfLType ltype,
int  id_code 
)

Set the ID code for a DXF LTYPE entity.

Parameters:
ltypea pointer to a DXF LTYPE entity.
id_codeIdentification number for the entity.
This is to be an unique (sequential) number in the DXF file.

Definition at line 686 of file ltype.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ltype_struct::id_code.

Referenced by dxf_ltype_init().

char* dxf_ltype_get_linetype_name ( DxfLType ltype)

Get the linetype_name from a DXF LTYPE entity.

Returns:
linetype_name when sucessful, NULL when an error occurred.
Parameters:
ltypea pointer to a DXF LTYPE entity.

Definition at line 729 of file ltype.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ltype_struct::linetype_name.

Referenced by dxf_ltype_free(), and dxf_ltype_write().

DxfLType* dxf_ltype_set_linetype_name ( DxfLType ltype,
char *  linetype_name 
)

Set the linetype_name for a DXF LTYPE entity.

Parameters:
ltypea pointer to a DXF LTYPE entity.
linetype_namea string containing the linetype_name for the entity.

Definition at line 764 of file ltype.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ltype_struct::linetype_name.

Referenced by dxf_ltype_init().

char* dxf_ltype_get_description ( DxfLType ltype)

Get the description from a DXF LTYPE entity.

Returns:
description when sucessful, NULL when an error occurred.
Parameters:
ltypea pointer to a DXF LTYPE entity.

Definition at line 806 of file ltype.c.

References _, dxf_ltype_struct::description, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

Referenced by dxf_ltype_free(), and dxf_ltype_write().

DxfLType* dxf_ltype_set_description ( DxfLType ltype,
char *  description 
)

Set the description for a DXF LTYPE entity.

Parameters:
ltypea pointer to a DXF LTYPE entity.
descriptiona string containing the description for the entity.

Definition at line 841 of file ltype.c.

References _, dxf_ltype_struct::description, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

Referenced by dxf_ltype_init().

char* dxf_ltype_get_complex_text_string ( DxfLType ltype,
int  i 
)

Get the complex_text_string indexed by i from a DXF LTYPE entity.

Returns:
complex_text_string when sucessful, NULL when an error occurred.
Parameters:
ltypea pointer to a DXF LTYPE entity.
iindex.

Definition at line 884 of file ltype.c.

References _, dxf_ltype_struct::complex_text_string, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and DXF_MAX_NUMBER_OF_DASH_LENGTH_ITEMS.

Referenced by dxf_ltype_free(), and dxf_ltype_write().

DxfLType* dxf_ltype_set_complex_text_string ( DxfLType ltype,
int  i,
char *  complex_text_string 
)

Set the complex_text_string for index i for a DXF LTYPE entity.

Parameters:
ltypea pointer to a DXF LTYPE entity.
iindex.
complex_text_stringa string containing the complex_text_string for index i of the entity.

Definition at line 936 of file ltype.c.

References _, dxf_ltype_struct::complex_text_string, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and DXF_MAX_NUMBER_OF_DASH_LENGTH_ITEMS.

Referenced by dxf_ltype_init().

double dxf_ltype_get_total_pattern_length ( DxfLType ltype)

Get the total_pattern_length from a DXF LTYPE entity.

Returns:
total_pattern_length.
Parameters:
ltypea pointer to a DXF LTYPE entity.

Definition at line 993 of file ltype.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ltype_struct::total_pattern_length.

Referenced by dxf_ltype_write().

DxfLType* dxf_ltype_set_total_pattern_length ( DxfLType ltype,
double  total_pattern_length 
)

Set the total_pattern_length for a DXF LTYPE entity.

Parameters:
ltypea pointer to a DXF LTYPE entity.
total_pattern_lengththe total_pattern_length to be set for the entity.

Definition at line 1021 of file ltype.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ltype_struct::total_pattern_length.

Referenced by dxf_ltype_init().

double dxf_ltype_get_complex_x_offset ( DxfLType ltype,
int  i 
)

Get the complex_x_offset indexed by i from a DXF LTYPE entity.

Returns:
complex_x_offset when sucessful.
Parameters:
ltypea pointer to a DXF LTYPE entity.
iindex.

Definition at line 1056 of file ltype.c.

References _, dxf_ltype_struct::complex_x_offset, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and DXF_MAX_NUMBER_OF_DASH_LENGTH_ITEMS.

Referenced by dxf_ltype_write().

DxfLType* dxf_ltype_set_complex_x_offset ( DxfLType ltype,
int  i,
double  complex_x_offset 
)

Set the complex_x_offset for index i for a DXF LTYPE entity.

Parameters:
ltypea pointer to a DXF LTYPE entity.
iindex.
complex_x_offseta double containing the complex_x_offset for index i of the entity.

Definition at line 1101 of file ltype.c.

References _, dxf_ltype_struct::complex_x_offset, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and DXF_MAX_NUMBER_OF_DASH_LENGTH_ITEMS.

Referenced by dxf_ltype_init().

double dxf_ltype_get_complex_y_offset ( DxfLType ltype,
int  i 
)

Get the complex_y_offset indexed by i from a DXF LTYPE entity.

Returns:
complex_y_offset when sucessful.
Parameters:
ltypea pointer to a DXF LTYPE entity.
iindex.

Definition at line 1152 of file ltype.c.

References _, dxf_ltype_struct::complex_y_offset, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and DXF_MAX_NUMBER_OF_DASH_LENGTH_ITEMS.

Referenced by dxf_ltype_write().

DxfLType* dxf_ltype_set_complex_y_offset ( DxfLType ltype,
int  i,
double  complex_y_offset 
)

Set the complex_y_offset for index i for a DXF LTYPE entity.

Parameters:
ltypea pointer to a DXF LTYPE entity.
iindex.
complex_y_offseta double containing the complex_y_offset for index i of the entity.

Definition at line 1197 of file ltype.c.

References _, dxf_ltype_struct::complex_y_offset, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and DXF_MAX_NUMBER_OF_DASH_LENGTH_ITEMS.

Referenced by dxf_ltype_init().

double dxf_ltype_get_complex_scale ( DxfLType ltype,
int  i 
)

Get the complex_scale indexed by i from a DXF LTYPE entity.

Returns:
complex_scale when sucessful.
Parameters:
ltypea pointer to a DXF LTYPE entity.
iindex.

Definition at line 1248 of file ltype.c.

References _, dxf_ltype_struct::complex_scale, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and DXF_MAX_NUMBER_OF_DASH_LENGTH_ITEMS.

Referenced by dxf_ltype_write().

DxfLType* dxf_ltype_set_complex_scale ( DxfLType ltype,
int  i,
double  complex_scale 
)

Set the complex_scale for index i for a DXF LTYPE entity.

Parameters:
ltypea pointer to a DXF LTYPE entity.
iindex.
complex_scalea double containing the complex_scale for index i of the entity.

Definition at line 1293 of file ltype.c.

References _, dxf_ltype_struct::complex_scale, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and DXF_MAX_NUMBER_OF_DASH_LENGTH_ITEMS.

Referenced by dxf_ltype_init().

double dxf_ltype_get_dash_length ( DxfLType ltype,
int  i 
)

Get the dash_length indexed by i from a DXF LTYPE entity.

Returns:
dash_length when sucessful.
Parameters:
ltypea pointer to a DXF LTYPE entity.
iindex.

Definition at line 1344 of file ltype.c.

References _, dxf_ltype_struct::dash_length, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and DXF_MAX_NUMBER_OF_DASH_LENGTH_ITEMS.

Referenced by dxf_ltype_write().

DxfLType* dxf_ltype_set_dash_length ( DxfLType ltype,
int  i,
double  dash_length 
)

Set the dash_length for index i for a DXF LTYPE entity.

Parameters:
ltypea pointer to a DXF LTYPE entity.
iindex.
dash_lengtha double containing the dash_length for index i of the entity.

Definition at line 1389 of file ltype.c.

References _, dxf_ltype_struct::dash_length, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and DXF_MAX_NUMBER_OF_DASH_LENGTH_ITEMS.

Referenced by dxf_ltype_init().

double dxf_ltype_get_complex_rotation ( DxfLType ltype,
int  i 
)

Get the complex_rotation indexed by i from a DXF LTYPE entity.

Returns:
complex_rotation when sucessful.
Parameters:
ltypea pointer to a DXF LTYPE entity.
iindex.

Definition at line 1440 of file ltype.c.

References _, dxf_ltype_struct::complex_rotation, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and DXF_MAX_NUMBER_OF_DASH_LENGTH_ITEMS.

Referenced by dxf_ltype_write().

DxfLType* dxf_ltype_set_complex_rotation ( DxfLType ltype,
int  i,
double  complex_rotation 
)

Set the complex_rotation for index i for a DXF LTYPE entity.

Parameters:
ltypea pointer to a DXF LTYPE entity.
iindex.
complex_rotationa double containing the complex_rotation for index i of the entity.

Definition at line 1485 of file ltype.c.

References _, dxf_ltype_struct::complex_rotation, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and DXF_MAX_NUMBER_OF_DASH_LENGTH_ITEMS.

Referenced by dxf_ltype_init().

int dxf_ltype_get_flag ( DxfLType ltype)

Get the flag from a DXF LTYPE entity.

Returns:
flag.
Parameters:
ltypea pointer to a DXF LTYPE entity.

Definition at line 1535 of file ltype.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ltype_struct::flag.

Referenced by dxf_ltype_write().

DxfLType* dxf_ltype_set_flag ( DxfLType ltype,
int  flag 
)

Set the flag for a DXF LTYPE entity.

Parameters:
ltypea pointer to a DXF ARC entity.
flagflag to be set for the entity.

Definition at line 1570 of file ltype.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ltype_struct::flag.

Referenced by dxf_ltype_init().

int dxf_ltype_is_xreferenced ( DxfLType ltype)

Test if ltype is externally dependent on an xref.

Returns:
TRUE when ltype is externally dependent on an xref, or FALSE when ltype is not externally dependent on an xref.
Parameters:
ltypea pointer to the DXF LTYPE symbol table entry.

Definition at line 1611 of file ltype.c.

References _, DXF_CHECK_BIT, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ltype_struct::flag.

int dxf_ltype_is_xresolved ( DxfLType ltype)

Test if ltype is externally dependent on a xref and has been successfully resolved.

Returns:
TRUE when ltype is externally dependent on a xref and has been successfully resolved, or FALSE when ltype is not externally dependent on a xref and has not been successfully resolved.
Parameters:
ltypea pointer to the DXF LTYPE symbol table entry.

Definition at line 1645 of file ltype.c.

References _, DXF_CHECK_BIT, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ltype_struct::flag.

int dxf_ltype_is_referenced ( DxfLType ltype)

Test if ltype is internally referenced by an entity.

Returns:
TRUE when ltype is internally referenced by an entity, or FALSE when ltype is not internally referenced by an entity.
Parameters:
ltypea pointer to the DXF LTYPE symbol table entry.

Definition at line 1677 of file ltype.c.

References _, DXF_CHECK_BIT, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ltype_struct::flag.

int dxf_ltype_get_alignment ( DxfLType ltype)

Get the alignment from a DXF LTYPE entity.

Returns:
alignment.
Parameters:
ltypea pointer to a DXF LTYPE entity.

Definition at line 1707 of file ltype.c.

References _, dxf_ltype_struct::alignment, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

Referenced by dxf_ltype_write().

DxfLType* dxf_ltype_set_alignment ( DxfLType ltype,
int  alignment 
)

Set the alignment for a DXF LTYPE entity.

Parameters:
ltypea pointer to a DXF ARC entity.
alignmentalignment to be set for the entity.

Definition at line 1742 of file ltype.c.

References _, dxf_ltype_struct::alignment, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

Referenced by dxf_ltype_init().

int dxf_ltype_get_number_of_linetype_elements ( DxfLType ltype)

Get the number_of_linetype_elements from a DXF LTYPE entity.

Returns:
number_of_linetype_elements.
Parameters:
ltypea pointer to a DXF LTYPE entity.

Definition at line 1782 of file ltype.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ltype_struct::number_of_linetype_elements.

Referenced by dxf_ltype_write().

DxfLType* dxf_ltype_set_number_of_linetype_elements ( DxfLType ltype,
int  number_of_linetype_elements 
)

Set the number_of_linetype_elements for a DXF LTYPE entity.

Parameters:
ltypea pointer to a DXF ARC entity.
number_of_linetype_elementsnumber_of_linetype_elements to be set for the entity.

Definition at line 1817 of file ltype.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ltype_struct::number_of_linetype_elements.

Referenced by dxf_ltype_init().

int dxf_ltype_get_complex_element ( DxfLType ltype,
int  i 
)

Get the complex_element indexed by i from a DXF LTYPE entity.

Returns:
complex_element when sucessful.
Parameters:
ltypea pointer to a DXF LTYPE entity.
iindex.

Definition at line 1859 of file ltype.c.

References _, dxf_ltype_struct::complex_element, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and DXF_MAX_NUMBER_OF_DASH_LENGTH_ITEMS.

Referenced by dxf_ltype_write().

DxfLType* dxf_ltype_set_complex_element ( DxfLType ltype,
int  i,
int  complex_element 
)

Set the complex_element for index i for a DXF LTYPE entity.

Parameters:
ltypea pointer to a DXF LTYPE entity.
iindex.
complex_elementan integer containing the complex_element for index i of the entity.

Definition at line 1904 of file ltype.c.

References _, dxf_ltype_struct::complex_element, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and DXF_MAX_NUMBER_OF_DASH_LENGTH_ITEMS.

Referenced by dxf_ltype_init().

int dxf_ltype_get_complex_shape_number ( DxfLType ltype,
int  i 
)

Get the complex_shape_number indexed by i from a DXF LTYPE entity.

Returns:
complex_shape_number when sucessful.
Parameters:
ltypea pointer to a DXF LTYPE entity.
iindex.

Definition at line 1955 of file ltype.c.

References _, dxf_ltype_struct::complex_shape_number, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and DXF_MAX_NUMBER_OF_DASH_LENGTH_ITEMS.

Referenced by dxf_ltype_write().

DxfLType* dxf_ltype_set_complex_shape_number ( DxfLType ltype,
int  i,
int  complex_shape_number 
)

Set the complex_shape_number for index i for a DXF LTYPE entity.

Parameters:
ltypea pointer to a DXF LTYPE entity.
iindex.
complex_shape_numberan integer containing the complex_shape_number for index i of the entity.

Definition at line 2000 of file ltype.c.

References _, dxf_ltype_struct::complex_shape_number, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and DXF_MAX_NUMBER_OF_DASH_LENGTH_ITEMS.

Referenced by dxf_ltype_init().

char* dxf_ltype_get_dictionary_owner_soft ( DxfLType ltype)

Get the soft pointer to the dictionary owner from a DXF LTYPE entity.

Returns:
soft pointer to the dictionary owner.
Warning:
No checks are performed on the returned pointer (string).
Parameters:
ltypea pointer to a DXF LTYPE entity.

Definition at line 2053 of file ltype.c.

References _, dxf_ltype_struct::dictionary_owner_soft, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

Referenced by dxf_ltype_free(), and dxf_ltype_write().

DxfLType* dxf_ltype_set_dictionary_owner_soft ( DxfLType ltype,
char *  dictionary_owner_soft 
)

Set the pointer to the dictionary_owner_soft for a DXF LTYPE entity.

Parameters:
ltypea pointer to a DXF LTYPE entity.
dictionary_owner_softa string containing the pointer to the dictionary_owner_soft for the entity.

Definition at line 2089 of file ltype.c.

References _, dxf_ltype_struct::dictionary_owner_soft, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

Referenced by dxf_ltype_init().

char* dxf_ltype_get_complex_style_pointer ( DxfLType ltype,
int  i 
)

Get the complex_style_pointer indexed by i from a DXF LTYPE entity.

Returns:
complex_style_pointer when sucessful, NULL when an error occurred.
Parameters:
ltypea pointer to a DXF LTYPE entity.
iindex.

Definition at line 2132 of file ltype.c.

References _, dxf_ltype_struct::complex_style_pointer, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and DXF_MAX_NUMBER_OF_DASH_LENGTH_ITEMS.

Referenced by dxf_ltype_free(), and dxf_ltype_write().

DxfLType* dxf_ltype_set_complex_style_pointer ( DxfLType ltype,
int  i,
char *  complex_style_pointer 
)

Set the complex_style_pointer for index i for a DXF LTYPE entity.

Parameters:
ltypea pointer to a DXF LTYPE entity.
iindex.
complex_style_pointera string containing the complex_style_pointer for index i of the entity.

Definition at line 2184 of file ltype.c.

References _, dxf_ltype_struct::complex_style_pointer, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and DXF_MAX_NUMBER_OF_DASH_LENGTH_ITEMS.

Referenced by dxf_ltype_init().

char* dxf_ltype_get_dictionary_owner_hard ( DxfLType ltype)

Get the hard pointer to the dictionary owner from a DXF LTYPE entity.

Returns:
hard pointer to the dictionary owner.
Warning:
No checks are performed on the returned pointer (string).
Parameters:
ltypea pointer to a DXF LTYPE entity.

Definition at line 2244 of file ltype.c.

References _, dxf_ltype_struct::dictionary_owner_hard, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

Referenced by dxf_ltype_free(), and dxf_ltype_write().

DxfLType* dxf_ltype_set_dictionary_owner_hard ( DxfLType ltype,
char *  dictionary_owner_hard 
)

Set the pointer to the dictionary_owner_hard for a DXF LTYPE entity.

Parameters:
ltypea pointer to a DXF LTYPE entity.
dictionary_owner_harda string containing the pointer to the dictionary_owner_hard for the entity.

Definition at line 2280 of file ltype.c.

References _, dxf_ltype_struct::dictionary_owner_hard, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

Referenced by dxf_ltype_init().

DxfLType* dxf_ltype_get_next ( DxfLType ltype)

Get the pointer to the next LTYPE entity from a DXF LTYPE entity.

Returns:
pointer to the next LTYPE entity.
Warning:
No checks are performed on the returned pointer.
Parameters:
ltypea pointer to a DXF LTYPE entity.

Definition at line 2324 of file ltype.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ltype_struct::next.

DxfLType* dxf_ltype_set_next ( DxfLType ltype,
DxfLType next 
)

Set the pointer to the next LTYPE for a DXF LTYPE entity.

Parameters:
ltypea pointer to a DXF LTYPE entity.
nexta pointer to the next LTYPE for the entity.

Definition at line 2360 of file ltype.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ltype_struct::next.

DxfLType* dxf_ltype_get_last ( DxfLType ltype)

Get the pointer to the last LTYPE entity from a linked list of DXF LTYPE entities.

Returns:
pointer to the last LTYPE entity.
Warning:
No checks are performed on the returned pointer.
Parameters:
ltypea pointer to a DXF LTYPE entity.

Definition at line 2403 of file ltype.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ltype_struct::next.