libgeda

prototype_priv.h File Reference

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

gchar * o_save_objects (TOPLEVEL *toplevel, const GList *object_list, gboolean save_attribs)
void f_print_set_line_width (FILE *fp, int width)
 Prints the line width in mils to a postscript document.
int f_print_set_color (TOPLEVEL *toplevel, FILE *fp, int color)
 Prints the color to a postscript document.
int f_print_header (TOPLEVEL *toplevel, PAGE *page, FILE *fp, int paper_size_x, int paper_size_y, int eps)
 Prints the header to a postscript document.
void f_print_footer (FILE *fp)
 Prints the footer to a postscript document.
void f_print_objects (TOPLEVEL *toplevel, FILE *fp, const GList *obj_list, int start_x, int start_y, float scale, int unicode_count, gunichar *unicode_table)
 Print all objects from the toplevel TOPLEVEL object.
int f_print_initialize_glyph_table (void)
 Initializes the glyph translation table.
int vstbl_lookup_str (const vstbl_entry *table, int size, const char *str)
int vstbl_get_val (const vstbl_entry *table, int index)
SCM g_rc_component_library (SCM path, SCM name)
SCM g_rc_component_library_command (SCM listcmd, SCM getcmd, SCM name)
 Guile callback for adding library commands.
SCM g_rc_component_library_funcs (SCM listfunc, SCM getfunc, SCM name)
 Guile callback for adding library functions.
SCM g_rc_source_library (SCM path)
SCM g_rc_source_library_search (SCM path)
SCM g_rc_world_size (SCM width, SCM height, SCM border)
SCM g_rc_reset_component_library (void)
SCM g_rc_reset_source_library (void)
SCM g_rc_untitled_name (SCM name)
SCM g_rc_bitmap_directory (SCM path)
SCM g_rc_scheme_directory (SCM path)
 Add a directory to the Guile load path.
SCM g_rc_bus_ripper_symname (SCM scmsymname)
SCM g_rc_postscript_prolog (SCM scmsymname)
SCM g_rc_map_font_character_to_file (SCM character_param, SCM file_param)
SCM g_rc_attribute_promotion (SCM mode)
SCM g_rc_promote_invisible (SCM mode)
SCM g_rc_keep_invisible (SCM mode)
SCM g_rc_always_promote_attributes (SCM scmsymname)
SCM g_rc_make_backup_files (SCM mode)
 Enable the creation of backup files when saving.
SCM g_rc_print_color_map (SCM scm_map)
void g_register_libgeda_funcs (void)
 Register all libgeda functions with scheme.
void g_register_libgeda_dirs (void)
 Register some libgeda directories with Scheme.
void m_bounds_init (BOUNDS *bounds)
 Initialize a bounds by setting it to empty.
void m_bounds_of_points (BOUNDS *bounds, sPOINT points[], gint count)
 Calculate the bounds of a set of points.
double m_box_shortest_distance (BOX *box, int x, int y, int solid)
 Calculates the distance between the given point and the closest point on the perimeter or interior of the box.
double m_circle_shortest_distance (CIRCLE *circle, int x, int y, int solid)
 Calculates the distance between the given point and the closest point on the perimeter or interior of the circle.
void m_hatch_polygon (GArray *points, gint angle, gint pitch, GArray *lines)
 Calculates line segments to hatch an arbitrary polygon.
double m_line_shortest_distance (LINE *circle, int x, int y)
 Calculates the distance between the given point and the closest point on the given line segment.
gboolean m_polygon_interior_point (GArray *points, int x, int y)
 Determines if a point lies inside a polygon.
double m_polygon_shortest_distance (GArray *points, int x, int y, gboolean closed)
 Calculates the distance between the given point and the closest point on the perimeter of the polygon.
void m_transform_combine (TRANSFORM *result, TRANSFORM *a, TRANSFORM *b)
 Combines two transformations.
void m_transform_init (TRANSFORM *transform)
 Initialize a transform with the identity matrix.
void m_transform_invert (TRANSFORM *transform, TRANSFORM *inverse)
 Calculates the inverse transform.
void m_transform_line (TRANSFORM *transform, LINE *line)
 Transforms a line segment.
void m_transform_lines (TRANSFORM *transform, GArray *lines)
 Transforms multiple line segments.
void m_transform_point (TRANSFORM *transform, gint *x, gint *y)
 Transforms a point.
void m_transform_points (TRANSFORM *transform, GArray *points)
 Transforms a polyline or polygon.
void m_transform_rotate (TRANSFORM *transform, gdouble angle)
 Adds a rotation to the transformation.
void m_transform_scale (TRANSFORM *transform, gdouble factor)
 Adds a scaling to the transformation.
void m_transform_translate (TRANSFORM *transform, gdouble dx, gdouble dy)
 Adds a translation to the transformation.
OBJECTo_arc_read (TOPLEVEL *toplevel, const char buf[], unsigned int release_ver, unsigned int fileformat_ver, GError **err)
char * o_arc_save (TOPLEVEL *toplevel, OBJECT *object)
 create the string representation of an arc object
void o_arc_print (TOPLEVEL *toplevel, FILE *fp, OBJECT *o_current, int origin_x, int origin_y)
void o_arc_print_solid (TOPLEVEL *toplevel, FILE *fp, int x, int y, int radius, int angle1, int angle2, int color, int arc_width, int length, int space, int origin_x, int origin_y)
void o_arc_print_dotted (TOPLEVEL *toplevel, FILE *fp, int x, int y, int radius, int angle1, int angle2, int color, int arc_width, int length, int space, int origin_x, int origin_y)
void o_arc_print_dashed (TOPLEVEL *toplevel, FILE *fp, int x, int y, int radius, int angle1, int angle2, int color, int arc_width, int length, int space, int origin_x, int origin_y)
void o_arc_print_center (TOPLEVEL *toplevel, FILE *fp, int x, int y, int radius, int angle1, int angle2, int color, int arc_width, int length, int space, int origin_x, int origin_y)
void o_arc_print_phantom (TOPLEVEL *toplevel, FILE *fp, int x, int y, int radius, int angle1, int angle2, int color, int arc_width, int length, int space, int origin_x, int origin_y)
double o_arc_shortest_distance (OBJECT *object, int x, int y, int force_soild)
 Calculates the distance between the given point and the closest point on the perimeter of the arc.
gboolean o_arc_within_sweep (ARC *arc, gint x, gint y)
 Determines if a point lies within the sweep of the arc.
void world_get_arc_bounds (TOPLEVEL *toplevel, OBJECT *object, int *left, int *top, int *right, int *bottom)
gboolean o_arc_get_position (TOPLEVEL *toplevel, gint *x, gint *y, OBJECT *object)
 get the position of the center point
void o_arc_recalc (TOPLEVEL *toplevel, OBJECT *o_current)
GList * o_read_attribs (TOPLEVEL *toplevel, OBJECT *object_to_get_attribs, TextBuffer *tb, unsigned int release_ver, unsigned int fileformat_ver, GError **err)
 Read attributes from a buffer.
OBJECTo_attrib_find_attrib_by_name (const GList *list, char *name, int count)
 Find an attribute in a list.
void o_bounds_invalidate (TOPLEVEL *toplevel, OBJECT *object)
 Mark an OBJECT's cached bounds as invalid.
double o_shortest_distance_full (OBJECT *object, int x, int y, int force_solid)
 Calculates the distance between the given point and the closest point on the given object. Allows forcing objects to solid.
PAGEo_get_page_compat (TOPLEVEL *toplevel, OBJECT *object) G_GNUC_DEPRECATED
 Get an object's parent PAGE, or fall back to global current page.
void o_emit_pre_change_notify (TOPLEVEL *toplevel, OBJECT *object)
 Emit an object pre-change notification.
void o_emit_change_notify (TOPLEVEL *toplevel, OBJECT *object)
 Emit an object change notification.
OBJECTo_box_read (TOPLEVEL *toplevel, const char buf[], unsigned int release_ver, unsigned int fileformat_ver, GError **err)
 Create a box from a character string.
char * o_box_save (TOPLEVEL *toplevel, OBJECT *object)
 Create a character string representation of a BOX.
void o_box_print (TOPLEVEL *toplevel, FILE *fp, OBJECT *o_current, int origin_x, int origin_y)
 Print BOX to Postscript document.
void o_box_print_solid (TOPLEVEL *toplevel, FILE *fp, int x, int y, int width, int height, int color, int line_width, int length, int space, int origin_x, int origin_y)
 Print a solid BOX to Postscript document.
void o_box_print_dotted (TOPLEVEL *toplevel, FILE *fp, int x, int y, int width, int height, int color, int line_width, int length, int space, int origin_x, int origin_y)
 Print a dotted BOX to Postscript document.
void o_box_print_dashed (TOPLEVEL *toplevel, FILE *fp, int x, int y, int width, int height, int color, int line_width, int length, int space, int origin_x, int origin_y)
 Print a dashed BOX to Postscript document.
void o_box_print_center (TOPLEVEL *toplevel, FILE *fp, int x, int y, int width, int height, int color, int line_width, int length, int space, int origin_x, int origin_y)
 Print centered line type BOX to Postscript document.
void o_box_print_phantom (TOPLEVEL *toplevel, FILE *fp, int x, int y, int width, int height, int color, int line_width, int length, int space, int origin_x, int origin_y)
 Print phantom line type BOX to Postscript document.
void o_box_print_filled (TOPLEVEL *toplevel, FILE *fp, int x, int y, int width, int height, int color, int fill_width, int angle1, int pitch1, int angle2, int pitch2, int origin_x, int origin_y)
 Print a solid pattern BOX to Postscript document.
void o_box_print_mesh (TOPLEVEL *toplevel, FILE *fp, int x, int y, int width, int height, int color, int fill_width, int angle1, int pitch1, int angle2, int pitch2, int origin_x, int origin_y)
 Print a mesh pattern BOX to Postscript document.
void o_box_print_hatch (TOPLEVEL *toplevel, FILE *fp, int x, int y, int width, int height, int color, int fill_width, int angle1, int pitch1, int angle2, int pitch2, int origin_x, int origin_y)
 Print a hatch pattern BOX to Postscript document.
double o_box_shortest_distance (OBJECT *object, int x, int y, int force_soild)
 Calculates the distance between the given point and the closest point on the perimeter of the box.
void world_get_box_bounds (TOPLEVEL *toplevel, OBJECT *object, int *left, int *top, int *right, int *bottom)
 Get BOX bounding rectangle in WORLD coordinates.
gboolean o_box_get_position (TOPLEVEL *toplevel, gint *x, gint *y, OBJECT *object)
 get the position of the left bottom point
void o_box_recalc (TOPLEVEL *toplevel, OBJECT *o_current)
 Recalculate BOX coordinates in WORLD units.
OBJECTo_bus_read (TOPLEVEL *toplevel, const char buf[], unsigned int release_ver, unsigned int fileformat_ver, GError **err)
 read a bus object from a char buffer
char * o_bus_save (TOPLEVEL *toplevel, OBJECT *object)
 Create a string representation of the bus object.
void o_bus_print (TOPLEVEL *toplevel, FILE *fp, OBJECT *o_current, int origin_x, int origin_y)
 postscript print command for a bus object
void world_get_bus_bounds (TOPLEVEL *toplevel, OBJECT *object, int *left, int *top, int *right, int *bottom)
 calculate and return the boundaries of a bus object
gboolean o_bus_get_position (TOPLEVEL *toplevel, gint *x, gint *y, OBJECT *object)
 get the position of the first bus point
void o_bus_recalc (TOPLEVEL *toplevel, OBJECT *o_current)
 recalc the visual properties of a bus object
OBJECTo_circle_read (TOPLEVEL *toplevel, const char buf[], unsigned int release_ver, unsigned int fileformat_ver, GError **err)
 Create circle OBJECT from character string.
char * o_circle_save (TOPLEVEL *toplevel, OBJECT *object)
 Create a character string representation of a circle OBJECT.
void o_circle_print (TOPLEVEL *toplevel, FILE *fp, OBJECT *o_current, int origin_x, int origin_y)
 Print circle to Postscript document.
void o_circle_print_solid (TOPLEVEL *toplevel, FILE *fp, int x, int y, int radius, int color, int circle_width, int length, int space, int origin_x, int origin_y)
 Print a solid circle to Postscript document.
void o_circle_print_dotted (TOPLEVEL *toplevel, FILE *fp, int x, int y, int radius, int color, int circle_width, int length, int space, int origin_x, int origin_y)
 Print a dotted circle to Postscript document.
void o_circle_print_dashed (TOPLEVEL *toplevel, FILE *fp, int x, int y, int radius, int color, int circle_width, int length, int space, int origin_x, int origin_y)
 Print a dashed circle to Postscript document.
void o_circle_print_center (TOPLEVEL *toplevel, FILE *fp, int x, int y, int radius, int color, int circle_width, int length, int space, int origin_x, int origin_y)
 Print a centered line type circle to Postscript document.
void o_circle_print_phantom (TOPLEVEL *toplevel, FILE *fp, int x, int y, int radius, int color, int circle_width, int length, int space, int origin_x, int origin_y)
 Print a phantom line type circle to Postscript document.
void o_circle_print_filled (TOPLEVEL *toplevel, FILE *fp, int x, int y, int radius, int color, int fill_width, int angle1, int pitch1, int angle2, int pitch2, int origin_x, int origin_y)
 Print a solid pattern circle to Postscript document.
void o_circle_print_mesh (TOPLEVEL *toplevel, FILE *fp, int x, int y, int radius, int color, int fill_width, int angle1, int pitch1, int angle2, int pitch2, int origin_x, int origin_y)
 Print a mesh pattern circle to Postscript document.
void o_circle_print_hatch (TOPLEVEL *toplevel, FILE *fp, int x, int y, int radius, int color, int fill_width, int angle1, int pitch1, int angle2, int pitch2, int origin_x, int origin_y)
 Print a hatch pattern circle to Postscript document.
double o_circle_shortest_distance (OBJECT *object, int x, int y, int force_soild)
 Calculates the distance between the given point and the closest point on the perimeter of the circle.
void world_get_circle_bounds (TOPLEVEL *toplevel, OBJECT *object, int *left, int *top, int *right, int *bottom)
 Get circle bounding rectangle in WORLD coordinates.
gboolean o_circle_get_position (TOPLEVEL *toplevel, gint *x, gint *y, OBJECT *object)
 get the position of the center point
void o_circle_recalc (TOPLEVEL *toplevel, OBJECT *o_current)
 Recalculate circle coordinates in SCREEN units.
OBJECTo_complex_read (TOPLEVEL *toplevel, const char buf[], unsigned int release_ver, unsigned int fileformat_ver, GError **err)
 read a complex object from a char buffer
char * o_complex_save (TOPLEVEL *toplevel, OBJECT *object)
 Create a string representation of the complex object.
double o_complex_shortest_distance (OBJECT *object, int x, int y, int force_soild)
 Calculates the distance between the given point and the closest point on an object within the complex object.
void world_get_complex_bounds (TOPLEVEL *toplevel, OBJECT *complex, int *left, int *top, int *right, int *bottom)
 Queries the bounds of a complex object.
gboolean o_complex_get_position (TOPLEVEL *toplevel, gint *x, gint *y, OBJECT *object)
 get the position of the complex base point
void o_complex_recalc (TOPLEVEL *toplevel, OBJECT *o_current)
 update the visual boundaries of the complex object
GList * o_complex_get_promotable (TOPLEVEL *toplevel, OBJECT *object, int detach)
 Get attributes eligible for promotion from inside a complex.
OBJECTo_line_read (TOPLEVEL *toplevel, const char buf[], unsigned int release_ver, unsigned int fileformat_ver, GError **err)
 Create line OBJECT from character string.
char * o_line_save (TOPLEVEL *toplevel, OBJECT *object)
 Create a character string representation of a line OBJECT.
void o_line_print (TOPLEVEL *toplevel, FILE *fp, OBJECT *o_current, int origin_x, int origin_y)
 Print line to Postscript document.
void o_line_print_solid (TOPLEVEL *toplevel, FILE *fp, int x1, int y1, int x2, int y2, int color, int line_width, int length, int space, int origin_x, int origin_y)
 Print a solid line to Postscript document.
void o_line_print_dotted (TOPLEVEL *toplevel, FILE *fp, int x1, int y1, int x2, int y2, int color, int line_width, int length, int space, int origin_x, int origin_y)
 Print a dotted line to Postscript document.
void o_line_print_dashed (TOPLEVEL *toplevel, FILE *fp, int x1, int y1, int x2, int y2, int color, int line_width, int length, int space, int origin_x, int origin_y)
 Print a dashed line to Postscript document.
void o_line_print_center (TOPLEVEL *toplevel, FILE *fp, int x1, int y1, int x2, int y2, int color, int line_width, int length, int space, int origin_x, int origin_y)
 Print a centered line type line to Postscript document.
void o_line_print_phantom (TOPLEVEL *toplevel, FILE *fp, int x1, int y1, int x2, int y2, int color, int line_width, int length, int space, int origin_x, int origin_y)
 Print a phantom line type line to Postscript document.
double o_line_shortest_distance (OBJECT *object, int x, int y, int force_soild)
 Calculates the distance between the given point and the closest point on the given line segment.
void world_get_line_bounds (TOPLEVEL *toplevel, OBJECT *object, int *left, int *top, int *right, int *bottom)
 Get line bounding rectangle in WORLD coordinates.
gboolean o_line_get_position (TOPLEVEL *toplevel, gint *x, gint *y, OBJECT *object)
 get the position of the first line point
void o_line_recalc (TOPLEVEL *toplevel, OBJECT *o_current)
 Recalculate line coordinates in SCREEN units.
OBJECTo_net_read (TOPLEVEL *toplevel, const char buf[], unsigned int release_ver, unsigned int fileformat_ver, GError **err)
 read a net object from a char buffer
char * o_net_save (TOPLEVEL *toplevel, OBJECT *object)
 Create a string representation of the net object.
void o_net_print (TOPLEVEL *toplevel, FILE *fp, OBJECT *o_current, int origin_x, int origin_y)
 postscript print command for a net object
void world_get_net_bounds (TOPLEVEL *toplevel, OBJECT *object, int *left, int *top, int *right, int *bottom)
 calculate and return the boundaries of a net object
gboolean o_net_get_position (TOPLEVEL *toplevel, gint *x, gint *y, OBJECT *object)
 get the position of the first net point
void o_net_recalc (TOPLEVEL *toplevel, OBJECT *o_current)
 recalc the visual properties of a net object
OBJECTo_path_read (TOPLEVEL *toplevel, const char *first_line, TextBuffer *tb, unsigned int release_ver, unsigned int fileformat_ver, GError **err)
 Create path OBJECT from character string.
char * o_path_save (TOPLEVEL *toplevel, OBJECT *object)
 Create a character string representation of a path OBJECT.
void o_path_print (TOPLEVEL *toplevel, FILE *fp, OBJECT *o_current, int origin_x, int origin_y)
 Print PATH to Postscript document.
double o_path_shortest_distance (OBJECT *object, int x, int y, int force_soild)
 Calculates the distance between the given point and the closest point on the given path segment.
void world_get_path_bounds (TOPLEVEL *toplevel, OBJECT *object, int *left, int *top, int *right, int *bottom)
 Get path bounding rectangle in WORLD coordinates.
gboolean o_path_get_position (TOPLEVEL *toplevel, gint *x, gint *y, OBJECT *object)
 get the position of the first path point
void o_path_recalc (TOPLEVEL *toplevel, OBJECT *o_current)
 Recalculate path coordinates in SCREEN units.
OBJECTo_picture_read (TOPLEVEL *toplevel, const char *first_line, TextBuffer *tb, unsigned int release_ver, unsigned int fileformat_ver, GError **err)
 Create picture OBJECT from character string.
char * o_picture_save (TOPLEVEL *toplevel, OBJECT *object)
 Create a character string representation of a picture OBJECT.
void o_picture_print (TOPLEVEL *toplevel, FILE *fp, OBJECT *o_current, int origin_x, int origin_y)
 Print picture to Postscript document.
double o_picture_shortest_distance (OBJECT *object, int x, int y, int force_soild)
 Calculates the distance between the given point and the closest point in the picture.
void world_get_picture_bounds (TOPLEVEL *toplevel, OBJECT *object, int *left, int *top, int *right, int *bottom)
 Get picture bounding rectangle in WORLD coordinates.
gboolean o_picture_get_position (TOPLEVEL *toplevel, gint *x, gint *y, OBJECT *object)
 get the position of the left bottom point
void o_picture_recalc (TOPLEVEL *toplevel, OBJECT *o_current)
 Recalculate picture bounding box.
void o_picture_embed (TOPLEVEL *toplevel, OBJECT *object)
 Embed the image file associated with a picture.
void o_picture_unembed (TOPLEVEL *toplevel, OBJECT *object)
 Unembed a picture, reloading the image from disk.
OBJECTo_pin_read (TOPLEVEL *toplevel, const char buf[], unsigned int release_ver, unsigned int fileformat_ver, GError **err)
 read a pin object from a char buffer
char * o_pin_save (TOPLEVEL *toplevel, OBJECT *object)
 Create a string representation of the pin object.
void o_pin_print (TOPLEVEL *toplevel, FILE *fp, OBJECT *o_current, int origin_x, int origin_y)
 postscript print command for a pin object
void world_get_pin_bounds (TOPLEVEL *toplevel, OBJECT *object, int *left, int *top, int *right, int *bottom)
 calculate and return the boundaries of a pin object
gboolean o_pin_get_position (TOPLEVEL *toplevel, gint *x, gint *y, OBJECT *object)
 get the position of a whichend of the pin object
void o_pin_recalc (TOPLEVEL *toplevel, OBJECT *o_current)
 recalc the visual properties of a pin object
OBJECTo_text_read (TOPLEVEL *toplevel, const char *first_line, TextBuffer *tb, unsigned int release_ver, unsigned int fileformat_ver, GError **err)
 read a text object from a char buffer
char * o_text_save (TOPLEVEL *toplevel, OBJECT *object)
 Create a string representation of the text object.
void o_text_print_text_string (FILE *fp, char *string, int unicode_count, gunichar *unicode_table)
 write a text string to a postscript file
void o_text_print (TOPLEVEL *toplevel, FILE *fp, OBJECT *o_current, int origin_x, int origin_y, int unicode_count, gunichar *unicode_table)
 print a text object into a postscript file
double o_text_shortest_distance (OBJECT *object, int x, int y, int force_soild)
 Calculates the distance between the given point and the closest point on the text.
int world_get_text_bounds (TOPLEVEL *toplevel, OBJECT *o_current, int *left, int *top, int *right, int *bottom)
 calculate and return the boundaries of a text object
gboolean o_text_get_position (TOPLEVEL *toplevel, gint *x, gint *y, OBJECT *object)
 get the position of a text object
void o_text_recalc (TOPLEVEL *toplevel, OBJECT *o_current)
 update the visual boundaries of the text object
void s_clib_init (void)
 Initialise the component library.
void s_color_init (void)
 Initialises the color subsystem.
gchar * s_color_ps_string (gint color)
CONNs_conn_return_new (OBJECT *other_object, int type, int x, int y, int whichone, int other_whichone)
 create a new connection object
int s_conn_uniq (GList *conn_list, CONN *input_conn)
 check if a connection is uniq in a list
int s_conn_remove_other (TOPLEVEL *toplevel, OBJECT *other_object, OBJECT *to_remove)
 remove a object from the connection list of another object
OBJECTs_conn_check_midpoint (OBJECT *o_current, int x, int y)
 Checks if a point is a midpoint of an OBJECT.
void s_conn_print (GList *conn_list)
 print all connections of a connection list
void s_conn_init (void)
gchar * s_encoding_base64_encode (gchar *src, guint srclen, guint *dstlenp, gboolean strict)
 Convert a buffer from binary to base64 representation.
gchar * s_encoding_base64_decode (gchar *src, guint srclen, guint *dstlenp)
 Convert a buffer from base64 to binary representation.
int s_path_to_polygon (PATH *path, GArray *points)
 Converts a path to a polygon.
double s_path_shortest_distance (PATH *path, int x, int y, int solid)
 Calculates the distance between the given point and the closest point on the given path segment.
TextBuffers_textbuffer_new (const gchar *data, const gint size)
 Create a new managed text buffer.
TextBuffers_textbuffer_free (TextBuffer *tb)
 Clean up a managed text buffer.
const gchar * s_textbuffer_next (TextBuffer *tb, const gssize count)
 Fetch a number of characters from a text buffer.
const gchar * s_textbuffer_next_line (TextBuffer *tb)
 Fetch the next line from a text buffer.
void s_tile_init (TOPLEVEL *toplevel, PAGE *p_current)
 initialize the array of tiles
void s_tile_add_object (TOPLEVEL *toplevel, OBJECT *object)
 add an object to the tile ssytem
void s_tile_remove_object (OBJECT *object)
 remove an object from the tiles
void s_tile_print (TOPLEVEL *toplevel, PAGE *page)
 print all objects for each tile
void s_tile_free_all (PAGE *p_current)
 free all object links from the tiles
void s_weakref_notify (void *dead_ptr, GList *weak_refs)
 Notify weak reference watchers that a structure is dead.
GList * s_weakref_add (GList *weak_refs, void(*notify_func)(void *, void *), void *user_data)
 Add a weak reference watcher to a weak ref list.
GList * s_weakref_remove (GList *weak_refs, void(*notify_func)(void *, void *), void *user_data)
 Remove a weak reference watcher from a weak ref list.
GList * s_weakref_add_ptr (GList *weak_refs, void **weak_pointer_loc)
 Add a weak pointer to a weak ref list.
GList * s_weakref_remove_ptr (GList *weak_refs, void **weak_pointer_loc)
 Remove a weak pointer from a weak ref list.

Function Documentation

gchar* o_save_objects ( TOPLEVEL toplevel,
const GList *  object_list,
gboolean  save_attribs 
)
void f_print_set_line_width ( FILE *  fp,
int  width 
)
Function Description
This function writes the line width in mils to the specified postscript document.
Parameters:
[in]fpThe postscript document to write to.
[in]widthThe width of the line in mils to set.

Definition at line 53 of file f_print.c.

int f_print_set_color ( TOPLEVEL toplevel,
FILE *  fp,
int  color 
)
Function Description
This function converts the color number passed to a string and prints it to the postscript document provided.
Parameters:
[in]toplevelThe current TOPLEVEL structure.
[in]fpThe postscript document to print the color to.
[in]colorInteger color to convert and print.
Returns:
1 if the colour is enabled, 0 if disabled.

Definition at line 71 of file f_print.c.

Here is the call graph for this function:

int f_print_header ( TOPLEVEL toplevel,
PAGE page,
FILE *  fp,
int  paper_size_x,
int  paper_size_y,
int  eps 
)
Function Description
This function will print a document preamble and header for a postscript document.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]pageThe page to create document for.
[in]fpThe postscript document to write to.
[in]paper_size_xThe width of the document on paper in inches.
[in]paper_size_yThe height of the document on paper in inches.
[in]epswhether to create a eps of a ps document
Returns:
0 on success, -1 on failure.

Definition at line 105 of file f_print.c.

void f_print_footer ( FILE *  fp)
Function Description
This function will print a document footer and end a postscript document.
Parameters:
[in]fpThe postscript document to write footer to.

Definition at line 217 of file f_print.c.

void f_print_objects ( TOPLEVEL toplevel,
FILE *  fp,
const GList *  obj_list,
int  start_x,
int  start_y,
float  scale,
int  unicode_count,
gunichar *  unicode_table 
)
Function Description
This function will parse the head parameter for all objects and write the to the postscript document.
Parameters:
[in]toplevelThe current TOPLEVEL object.
[in]fpThe postscript document to print to.
[in]obj_listList of objects to be printed.
[in]start_xX origin on page to start printing objects.
[in]start_yY origin on page to start printing objects.
[in]scaleScale factor for object output.
[in]unicode_countNumber of items in unicode table.
[in]unicode_tableTable of unicode items.
Returns:
void

Definition at line 238 of file f_print.c.

Here is the call graph for this function:

int f_print_initialize_glyph_table ( void  )
Function Description
Initializes the glyph translation table
Returns:
0

Definition at line 4441 of file f_print.c.

int vstbl_lookup_str ( const vstbl_entry table,
int  size,
const char *  str 
)
Todo:
Finish function documentation!!!
Function Description

Definition at line 55 of file g_rc.c.

int vstbl_get_val ( const vstbl_entry table,
int  index 
)
Todo:
Finish function documentation!!!
Function Description

Definition at line 73 of file g_rc.c.

SCM g_rc_component_library ( SCM  path,
SCM  name 
)
Function Description
Parameters:
[in]path
[in]nameOptional descriptive name for library directory.
Returns:
SCM_BOOL_T on success, SCM_BOOL_F otherwise.

Definition at line 408 of file g_rc.c.

Here is the call graph for this function:

SCM g_rc_component_library_command ( SCM  listcmd,
SCM  getcmd,
SCM  name 
)
Function Description
Callback function for the "component-library-command" Guile function, which can be used in the rc files to add a command to the component library.
Parameters:
[in]listcmdcommand to get a list of symbols
[in]getcmdcommand to get a symbol from the library
[in]nameOptional descriptive name for component source.
Returns:
SCM_BOOL_T on success, SCM_BOOL_F otherwise.

Bug:
this may be a security risk!
Bug:
this may be a security risk!

Definition at line 466 of file g_rc.c.

Here is the call graph for this function:

SCM g_rc_component_library_funcs ( SCM  listfunc,
SCM  getfunc,
SCM  name 
)
Function Description
Callback function for the "component-library-funcs" Guile function, which can be used in the rc files to add a set of Guile procedures for listing and generating symbols.
Parameters:
[in]listfuncA Scheme procedure which takes no arguments and returns a Scheme list of component names.
[in]getfuncA Scheme procedure which takes a component name as an argument and returns a symbol encoded in a string in gEDA format, or the #f if the component name is unknown.
[in]nameA descriptive name for this component source.
Returns:
SCM_BOOL_T on success, SCM_BOOL_F otherwise.

Definition at line 525 of file g_rc.c.

Here is the call graph for this function:

SCM g_rc_source_library ( SCM  path)
Todo:
Finish function description!!!
Function Description
Parameters:
[in]path
Returns:
SCM_BOOL_T on success, SCM_BOOL_F otherwise.

Definition at line 554 of file g_rc.c.

Here is the call graph for this function:

SCM g_rc_source_library_search ( SCM  path)
Todo:
Finish function description!!!
Function Description
Parameters:
[in]path
Returns:
SCM_BOOL_T on success, SCM_BOOL_F otherwise.

Definition at line 599 of file g_rc.c.

Here is the call graph for this function:

SCM g_rc_world_size ( SCM  width,
SCM  height,
SCM  border 
)
Todo:
Finish function description!!!
Function Description
Parameters:
[in]width
[in]height
[in]border
Returns:
SCM_BOOL_T always.

Definition at line 706 of file g_rc.c.

Here is the call graph for this function:

SCM g_rc_reset_component_library ( void  )
Todo:
Finish function description!!!
Function Description
Returns:
SCM_BOOL_T always.

Definition at line 886 of file g_rc.c.

Here is the call graph for this function:

SCM g_rc_reset_source_library ( void  )
Todo:
Finish function description!!!
Function Description
Returns:
SCM_BOOL_T always.

Definition at line 899 of file g_rc.c.

Here is the call graph for this function:

SCM g_rc_untitled_name ( SCM  name)
Todo:
Finish function description!!!
Function Description
Parameters:
[in]name
Returns:
SCM_BOOL_T always.

Definition at line 746 of file g_rc.c.

SCM g_rc_bitmap_directory ( SCM  path)
Todo:
Finish function description!!!
Function Description
Parameters:
[in]path
Returns:
SCM_BOOL_T on success, SCM_BOOL_F otherwise.

Definition at line 804 of file g_rc.c.

Here is the call graph for this function:

SCM g_rc_scheme_directory ( SCM  s_path)
Function Description
Prepends s_path to the Guile system 'load-path', after expanding environment variables.
Parameters:
[in]s_pathPath to be added.
Returns:
SCM_BOOL_T.

Definition at line 770 of file g_rc.c.

Here is the call graph for this function:

SCM g_rc_bus_ripper_symname ( SCM  scmsymname)
Todo:
Finish function description!!!
Function Description
Parameters:
[in]scmsymname
Returns:
SCM_BOOL_T always.

Definition at line 839 of file g_rc.c.

SCM g_rc_postscript_prolog ( SCM  scmsymname)
Todo:
Finish function description!!!
Function Description
Parameters:
[in]scmsymname
Returns:
SCM_BOOL_T always.

Definition at line 862 of file g_rc.c.

Here is the call graph for this function:

SCM g_rc_map_font_character_to_file ( SCM  character_param,
SCM  file_param 
)
SCM g_rc_attribute_promotion ( SCM  mode)
Todo:
Finish function documentation!!!
Function Description

Definition at line 913 of file g_rc.c.

SCM g_rc_promote_invisible ( SCM  mode)
Todo:
Finish function documentation!!!
Function Description

Definition at line 930 of file g_rc.c.

SCM g_rc_keep_invisible ( SCM  mode)
Todo:
Finish function documentation!!!
Function Description

Definition at line 947 of file g_rc.c.

SCM g_rc_always_promote_attributes ( SCM  attrlist)
Todo:
Finish function description!!!
Function Description
Parameters:
[in]attrlist
Returns:
SCM_BOOL_T always.

Definition at line 966 of file g_rc.c.

SCM g_rc_make_backup_files ( SCM  mode)
Function Description
If enabled then a backup file, of the form 'example.sch~', is created when saving a file.
Parameters:
[in]modeString. 'enabled' or 'disabled'
Returns:
Bool. False if mode is not a valid value; true if it is.

Definition at line 1022 of file g_rc.c.

SCM g_rc_print_color_map ( SCM  scm_map)

Definition at line 1036 of file g_rc.c.

Here is the call graph for this function:

void g_register_libgeda_funcs ( void  )
Function Description
Creates g_subr_t objects to make g_rc_* functions that are defined in g_rc.c visible to Scheme.

Definition at line 83 of file g_register.c.

void g_register_libgeda_dirs ( void  )
Function Description
Ensures that the default gEDA Scheme directory is added to the Guile load path.

Definition at line 100 of file g_register.c.

Here is the call graph for this function:

void m_bounds_init ( BOUNDS bounds)
Parameters:
bounds[in] The bounds to set to empty. This parameter must not be NULL.

Definition at line 28 of file m_bounds.c.

void m_bounds_of_points ( BOUNDS bounds,
sPOINT  points[],
gint  count 
)

For an empty set of points, this function returns an empty bounds.

Parameters:
bounds[out] The bounds of the given set of points. The bounds does not need to be initialized before calling this function, but this parameter must not be NULL.
points[in] The given set of points. If the count is greater than zero, this parameter must not be NULL.
count[in] The number of points in the set.

Definition at line 47 of file m_bounds.c.

Here is the call graph for this function:

double m_box_shortest_distance ( BOX box,
int  x,
int  y,
int  solid 
)
Parameters:
[in]boxThe box.
[in]xThe x coordinate of the given point.
[in]yThe y coordinate of the given point.
[in]solidTRUE if the box should be treated as solid, FALSE if the box should be treated as hollow.
Returns:
The shortest distance from the box to the point. With a solid shape, this function returns a distance of zero for interior points. With an invalid parameter, this function returns G_MAXDOUBLE.

Definition at line 49 of file m_box.c.

double m_circle_shortest_distance ( CIRCLE circle,
int  x,
int  y,
int  solid 
)
Parameters:
[in]circleThe circle.
[in]xThe x coordinate of the given point.
[in]yThe y coordinate of the given point.
[in]solidTRUE if the circle should be treated as solid, FALSE if the circle should be treated as hollow.
Returns:
The shortest distance from the circle to the point. With a solid shape, this function returns a distance of zero for interior points. With an invalid parameter, this function returns G_MAXDOUBLE.

Definition at line 49 of file m_circle.c.

void m_hatch_polygon ( GArray *  points,
gint  angle,
gint  pitch,
GArray *  lines 
)

This function appends new line segments to the lines GArray. For creating a hatch pattern, the GArray must be cleared before calling this function. For creating cross hatch patterns, this function can be called multiple times with a different angle or pitch while passing the same lines GArray.

Parameters:
points[in] The endpoints of the arbitrary closed polygon to hatch.
angle[in] The angle of the hatch lines with respect to the x axis.
pitch[in] The distance between hatch lines. This value must be greater than zero.
lines[inout] A GArray of LINE to contain the new hatch line segments. This function appends new line segments to the GArray and leaves existing GArray contents unchanged.

Definition at line 237 of file m_hatch.c.

Here is the call graph for this function:

double m_line_shortest_distance ( LINE line,
int  x,
int  y 
)

If the closest point on the line resides beyond the line segment's end point, this function returns the distance from the given point to the closest end point.

If the line represents a single point (the endpoints are the same), this function calcualtes the distance to that point.

Parameters:
[in]lineThe LINE object.
[in]xThe x coordinate of the given point.
[in]yThe y coordinate of the given point.
Returns:
The shortest distance from the object to the point. With an invalid parameter, this function returns G_MAXDOUBLE.

Definition at line 53 of file m_line.c.

gboolean m_polygon_interior_point ( GArray *  points,
int  x,
int  y 
)

TODO Untested

Parameters:
points[in] The vertices of the polygon. This function assumes the list of points represents a closed polygon. If the first and last point do not match, the line segment between them is implied. This parameter must not be NULL.
x[in] The x coordinate of the given point.
y[in] The y coordinate of the given point.
Returns:
TRUE if the point lies inside the polygon, FALSE if the point lies outside the polygon.

Definition at line 113 of file m_polygon.c.

double m_polygon_shortest_distance ( GArray *  points,
int  x,
int  y,
gboolean  closed 
)
Parameters:
[in]pointsThe polygon, where polygon != NULL.
[in]xThe x coordinate of the given point.
[in]yThe y coordinate of the given point.
[in]closedIf TRUE, the function treats the polygon as a closed shape, creating a line between the first and last points, if needed. If the first and last points are equal, or inherintly closed, this parameter does not matter.
Returns:
The shortest distance from the polygon to the point. With an invalid parameter, this function returns G_MAXDOUBLE.

Definition at line 155 of file m_polygon.c.

Here is the call graph for this function:

void m_transform_combine ( TRANSFORM result,
TRANSFORM a,
TRANSFORM b 
)

Combines two matricies using matrix multiplication: a*b.

Parameters:
result[out] The resulting transformation. If either operand is NULL, the contents of the result remain unaltered.
a[in] The second operand.
b[in] The second operand.

Definition at line 33 of file m_transform.c.

void m_transform_init ( TRANSFORM transform)
Parameters:
transform[out] The transform to initialize with the identity matrix.

Definition at line 51 of file m_transform.c.

void m_transform_invert ( TRANSFORM transform,
TRANSFORM inverse 
)
Parameters:
transform[in] The given matrix
inverse[out] The inverse of the given matrix.

Definition at line 68 of file m_transform.c.

void m_transform_line ( TRANSFORM transform,
LINE line 
)
Parameters:
transform[in] The transform function.
line[inout] The line to transform.

Definition at line 90 of file m_transform.c.

Here is the call graph for this function:

void m_transform_lines ( TRANSFORM transform,
GArray *  lines 
)
Parameters:
transform[in] The transform function.
lines[inout] The GArray of LINE to transform.

Definition at line 104 of file m_transform.c.

Here is the call graph for this function:

void m_transform_point ( TRANSFORM transform,
gint *  x,
gint *  y 
)
Parameters:
x[inout] The x coordinate to transform.
y[inout] The y coordinate to transform.
transform[in] The transform function.

Definition at line 123 of file m_transform.c.

void m_transform_points ( TRANSFORM transform,
GArray *  points 
)
Parameters:
transform[in] The transform function.
points[inout] The GArray of sPOINT to transform.

Definition at line 144 of file m_transform.c.

Here is the call graph for this function:

void m_transform_rotate ( TRANSFORM transform,
gdouble  angle 
)
Parameters:
transform[inout] The given matrix
angle[in] The angle to rotate

Definition at line 162 of file m_transform.c.

void m_transform_scale ( TRANSFORM transform,
gdouble  factor 
)
Parameters:
transform[inout] The given matrix
factor[in] The amount to scale the transform. This parameter must not be zero, or the matrix becomes singular.

Definition at line 185 of file m_transform.c.

void m_transform_translate ( TRANSFORM transform,
gdouble  dx,
gdouble  dy 
)
Parameters:
transform[inout] The given matrix.
dx[in] The amount to translate on the x axis.
dy[in] The amount to translate on the y axis.

Definition at line 202 of file m_transform.c.

OBJECT* o_arc_read ( TOPLEVEL toplevel,
const char  buf[],
unsigned int  release_ver,
unsigned int  fileformat_ver,
GError **  err 
)
Function Description
This function reads a formatted text buffer describing an arc in the gEDA file format and initializes the corresponding object.

Depending on the version of the file format the data extraction is performed differently : currently pre-20000704 and 20000704 on one hand and post-20000704 file format version on the other hand are supported. The version is specified in string pointed by fileformat_ver.

To get information on the various file formats have a look to the fileformats.html document.

The object is initialized with the functions o_set_line_options() and o_set_fill_options(). The second one is only used to put initialize unused values for an arc as an arc can not be filled.

The arc is allocated initialized with the function o_arc_new().

A negative or null radius is not allowed.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]buf
[in]release_ver
[in]fileformat_ver
Returns:
The ARC OBJECT that was created, or NULL on error.

Note:
Depending on the version of the file format used to describe this arc, the buffer is parsed differently. The unknown parameters of the less restrictive - the oldest - file format are set to common values

Definition at line 235 of file o_arc_basic.c.

Here is the call graph for this function:

char* o_arc_save ( TOPLEVEL toplevel,
OBJECT object 
)
Function Description
This function formats a string in the buffer *buf to describe the arc object *object. A pointer to the new allocated and formated string is returned. The string must be freed at some point.
Parameters:
[in]toplevel
[in]object
Returns:
the string representation of the arc object

Definition at line 311 of file o_arc_basic.c.

void o_arc_print ( TOPLEVEL toplevel,
FILE *  fp,
OBJECT o_current,
int  origin_x,
int  origin_y 
)
Function Description
This function writes in a postscript file the arc described by the o_current pointed object. The postscript resulting file is described by the fp file pointer.

Parameters of the arc are extracted from object pointed by o_current and formatted to suit future calls to specialized arc printing functions.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpThe postscript document to print to.
[in]o_current
[in]origin_x
[in]origin_y

Note:
Depending on the type of the line for this particular arc, the appropriate function is chosen among o_arc_print_solid(), o_arc_print_dotted(), o_arc_print_dashed(), o_arc_print_center() and o_arc_print_phantom().

The needed parameters for each of these types are extracted from the o_current object. Depending on the type, unused parameters are set to -1.

In the eventuality of a length and/or space null, the arc is printed solid to avoid and endless loop produced by other functions.

Definition at line 607 of file o_arc_basic.c.

Here is the call graph for this function:

void o_arc_print_solid ( TOPLEVEL toplevel,
FILE *  fp,
int  x,
int  y,
int  radius,
int  angle1,
int  angle2,
int  color,
int  arc_width,
int  length,
int  space,
int  origin_x,
int  origin_y 
)
Function Description
This function prints an arc when a solid line type is required. The arc is defined by its center in x and y, its radius in radius and the start and end angles of the arc on the circle. The postscript file is defined by the file pointer fp.

The parameters length and space are ignored whereas arc_width specifies the width of the printed line.

All dimensions are in mils, except angle1 and angle2 in degrees.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to postscript document.
[in]x
[in]y
[in]radius
[in]angle1
[in]angle2
[in]color
[in]arc_width
[in]length
[in]space
[in]origin_x
[in]origin_y

Definition at line 727 of file o_arc_basic.c.

Here is the call graph for this function:

void o_arc_print_dotted ( TOPLEVEL toplevel,
FILE *  fp,
int  x,
int  y,
int  radius,
int  angle1,
int  angle2,
int  color,
int  arc_width,
int  length,
int  space,
int  origin_x,
int  origin_y 
)
Function Description
This function prints an arc when a dotted line type is required. The arc is defined by its center in x and y, its radius in radius and the start and end angles of the arc on the circle. The postscript file is defined by the file pointer fp. The parameter length is ignored whereas arc_width specifies the diameter of the dots of the printed line and space the distance between two dots.

A negative value for space leads to an endless loop.

All dimensions are in mils, except angle1 and angle2 in degrees.

The function sets the color the line will be printed with.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to postscript document.
[in]x
[in]y
[in]radius
[in]angle1
[in]angle2
[in]color
[in]arc_width
[in]length
[in]space
[in]origin_x
[in]origin_y

Note:
Depending on the radius of the arc, the space parameter is changed into a small angle da. Starting from angle1 - the start angle - the dots are printed along the arc by increments of this new angle.

As da is rounded as an integer, it can take a null value which will make the function enter an endless loop. In such a case, the arc is printed solid. The da variable should never be negative except if space is negative.

Definition at line 778 of file o_arc_basic.c.

Here is the call graph for this function:

void o_arc_print_dashed ( TOPLEVEL toplevel,
FILE *  fp,
int  x,
int  y,
int  radius,
int  angle1,
int  angle2,
int  color,
int  arc_width,
int  length,
int  space,
int  origin_x,
int  origin_y 
)
Function Description
This function prints an arc when a dashed line type is required. The arc is defined by its center in x and y, its radius in radius and the start and end angles of the arc on the circle. The postscript file is defined by the file pointer fp. The parameter arc_width specifies the diameter of the dots of the printed line.

A negative value for space or length leads to an endless loop.

All dimensions are in mils, except angle1 and angle2 in degrees.

The function sets the color the line will be printed with.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to postscript document.
[in]x
[in]y
[in]radius
[in]angle1
[in]angle2
[in]color
[in]arc_width
[in]length
[in]space
[in]origin_x
[in]origin_y

Note:
Depending on the radius of the arc, the space (resp. length) parameter is changed into a small angle da (resp. db). Starting from angle1 - the start angle - the dashes are printed along the arc by increments of these new angles.

As da (resp. db) is rounded as an integer, it can take a null value which will make the function enter an endless loop. In such a case, the arc is printed solid. The da (resp. db) variable should never be negative except if space (resp. length) is negative.

It prints as many dashes of length length as possible.

Note:
When the above condition is no more satisfied, then it is not possible to print a dash of length length and the following space. However it may be possible to print the complete dash or a shorter one.

Definition at line 862 of file o_arc_basic.c.

Here is the call graph for this function:

void o_arc_print_center ( TOPLEVEL toplevel,
FILE *  fp,
int  x,
int  y,
int  radius,
int  angle1,
int  angle2,
int  color,
int  arc_width,
int  length,
int  space,
int  origin_x,
int  origin_y 
)
Function Description
This function prints an arc when a centered line type is required. The arc is defined by its center in x and y, its radius in radius and the start and end angles of the arc on the circle. The postscript file is defined by the file pointer fp. The parameter arc_width specifies the diameter of the dots and the width of the dashes of the printed line.

A negative value for space or length leads to an endless loop.

All dimensions are in mils, except angle1 and angle2 in degrees.

The function sets the color in which the line will be printed with.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to postscript document.
[in]x
[in]y
[in]radius
[in]angle1
[in]angle2
[in]color
[in]arc_width
[in]length
[in]space
[in]origin_x
[in]origin_y

Note:
Depending on the radius of the arc, the space (resp. length) parameter is changed into a small angle da (resp. db). Starting from angle1 - the start angle - the dashes are printed along the arc by increments of these new angles.

As da (resp. db) is rounded as an integer, it can take a null value which will make the function enter an endless loop. In such a case, the arc is printed solid. The da (resp. db) variable should never be negative except if space (resp. length) is negative.

It prints as many sets of dash-dot as possible.

Note:
When the above condition is no more satisfied, then it is not possible to print a dash of length length. However two cases are possible :
*
it is possible to print the dash and the dot
*
it is possible to print the dash or a part of the original dash

Definition at line 967 of file o_arc_basic.c.

Here is the call graph for this function:

void o_arc_print_phantom ( TOPLEVEL toplevel,
FILE *  fp,
int  x,
int  y,
int  radius,
int  angle1,
int  angle2,
int  color,
int  arc_width,
int  length,
int  space,
int  origin_x,
int  origin_y 
)
Note:
A dot is represented by a filled circle. Position of the circle is (xa, ya) and its radius is the arc_width parameter.
Function Description
This function prints an arc when a phantom line type is required. The arc is defined by its center in x and y, its radius in radius and the start and end angles of the arc on the circle. The postscript file is defined by the file pointer fp. The parameter arc_width specifies the diameter of the dots and the width of the dashes of the printed line.

A negative value for space or length leads to an endless loop.

All dimensions are in mils, except angle1 and angle2 in degrees.

The function sets the color in which the line will be printed with.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to postscript document.
[in]x
[in]y
[in]radius
[in]angle1
[in]angle2
[in]color
[in]arc_width
[in]length
[in]space
[in]origin_x
[in]origin_y

Note:
Depending on the radius of the arc, the space (resp. length) parameter is changed into a small angle da (resp. db). Starting from angle1 - the start angle - the dashes are printed along the arc by increments of these new angles.

As da (resp. db) is rounded as an integer, it can take a null value which will make the function enter an endless loop. In such a case, the arc is printed solid. The da (resp. db) variable should never be negative except if space (resp. length) is negative.

It prints as many sets of dash-dot-dot as possible.

Note:
When the above condition is no more satisfied, then it is not possible to print a dash of length length. However three cases are possible :
*
it is possible to print a dash and a dot and a dot
*
it is possible to print a dash and a dot
*
it is possible to print the dash or a part of the original dash

Definition at line 1095 of file o_arc_basic.c.

Here is the call graph for this function:

double o_arc_shortest_distance ( OBJECT object,
int  x,
int  y,
int  force_solid 
)
Parameters:
[in]objectThe arc OBJECT.
[in]xThe x coordinate of the given point.
[in]yThe y coordinate of the given point.
[in]force_solidIf true, force treating the object as solid.
Returns:
The shortest distance from the object to the point. With an invalid parameter, this function returns G_MAXDOUBLE.

Definition at line 1226 of file o_arc_basic.c.

Here is the call graph for this function:

gboolean o_arc_within_sweep ( ARC arc,
gint  x,
gint  y 
)
Parameters:
[in]arcThe arc of object
[in]xThe x coordinate of the given point.
[in]yThe y coordinate of the given point.
Returns:
TRUE if the point lies within the sweep of the arc. FALSE if the point lies outside the sweep of the arc. With an invalid parameter, this function returns FALSE.

Definition at line 1282 of file o_arc_basic.c.

void world_get_arc_bounds ( TOPLEVEL toplevel,
OBJECT object,
int *  left,
int *  top,
int *  right,
int *  bottom 
)
Function Description
This function calculates the smallest rectangle the arc can be drawn into. The OBJECT pointed by object is assumed to be an arc. The left, top, right and bottom pointed integers define this rectangle at the end of the function. It is expressed in world units. The process is divided into two steps : the first step is to calculate the coordinates of the two ends of the arc and the coordinates of the center. They forms a first rectangle but (depending on the start angle and the sweep of the arc) not the right.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]object
[out]left
[out]top
[out]right
[out]bottom

Note:
The previous rectangle is extended to the final one by checking whether the arc is over a main axis (vertical or horizontal). If so, the rectangle is extended in these directions.

In the mirror mode, the sweep angle is negativ. To get a CCW arc before this calculation we have to move the start angle to the end angle and reverse the sweep angle.

Definition at line 514 of file o_arc_basic.c.

gboolean o_arc_get_position ( TOPLEVEL toplevel,
gint *  x,
gint *  y,
OBJECT object 
)
Function Description
This function gets the position of the center point of an arc object.
Parameters:
[in]toplevelThe toplevel environment.
[out]xpointer to the x-position
[out]ypointer to the y-position
[in]objectThe object to get the position.
Returns:
TRUE if successfully determined the position, FALSE otherwise

Definition at line 584 of file o_arc_basic.c.

void o_arc_recalc ( TOPLEVEL toplevel,
OBJECT o_current 
)
Function Description
This function recalculates internal parameters in screen units of an object containing an arc. The object is given as parameters o_current. The calculation is done according to the zoom factor detailed in the toplevel pointed structure. It also recalculates the OBJECT specific fields and the bounding box of the arc.

The bounding box - in world units - is recalculated with the world_get_arc_bounds() function.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]o_current

Definition at line 478 of file o_arc_basic.c.

Here is the call graph for this function:

GList* o_read_attribs ( TOPLEVEL toplevel,
OBJECT object_to_get_attribs,
TextBuffer tb,
unsigned int  release_ver,
unsigned int  fileformat_ver,
GError **  err 
)
Function Description
Read attributes from a TextBuffer.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]object_to_get_attribsObject which gets these attribs.
[in]tbThe text buffer to read from.
[in]release_verlibgeda release version number.
[in]fileformat_verfile format version number.
Returns:
GList of attributes read, or NULL on error.

Definition at line 247 of file o_attrib.c.

Here is the call graph for this function:

OBJECT* o_attrib_find_attrib_by_name ( const GList *  list,
char *  name,
int  count 
)
Function Description
Search for attribute by name.

Counter is the n'th occurance of the attribute, and starts searching from zero. Zero is the first occurance of an attribute.

Parameters:
[in]listGList of attributes to search.
[in]nameCharacter string with attribute name to search for.
[in]countWhich occurance to return.
Returns:
The n'th attribute object in the given list with the given name.

Definition at line 479 of file o_attrib.c.

Here is the call graph for this function:

void o_bounds_invalidate ( TOPLEVEL toplevel,
OBJECT obj 
)
Function Description
Recursively marks the cached bounds of the given OBJECT and its parents as having been invalidated and in need of an update. They will be recalculated next time the OBJECT's bounds are requested (e.g. via world_get_single_object_bounds() ).
Parameters:
[in]toplevel
[in]obj
Todo:
Turn this into a macro?

Definition at line 564 of file o_basic.c.

double o_shortest_distance_full ( OBJECT object,
int  x,
int  y,
int  force_solid 
)
Parameters:
[in]objectThe given object.
[in]xThe x coordinate of the given point.
[in]yThe y coordinate of the given point.
[in]force_solidIf true, force treating the object as solid.
Returns:
The shortest distance from the object to the point. If the distance cannot be calculated, this function returns a really large number (G_MAXDOUBLE). If an error occurs, this function returns G_MAXDOUBLE.

Definition at line 521 of file o_basic.c.

Here is the call graph for this function:

PAGE* o_get_page_compat ( TOPLEVEL toplevel,
OBJECT object 
)
Function Description
If set, returns the PAGE structure which owns object. If object does not have a parent page set, returns the global current page from toplevel. If the object parent page is inconsistent with the global current page, a critical-level error message is emitted.
Warning:
This function is primarily intended to assist in the migration of code from using the TOPLEVEL current page to using the o_get_page(). It should not be used in new code.
Deprecated:
Use o_get_page() in new code.
Parameters:
[in]toplevelThe TOPLEVEL structure.
[in]objectThe OBJECT for which to retrieve the parent PAGE.
Returns:
The PAGE which owns object, the global current PAGE, or NULL.

Definition at line 635 of file o_basic.c.

Here is the call graph for this function:

void o_emit_pre_change_notify ( TOPLEVEL toplevel,
OBJECT object 
)
Function Description
Calls each pre-change callback function registered with TOPLEVEL to notify listeners that object is about to be modified. All libgeda functions that modify OBJECT structures should call this just before making a change to an OBJECT.
Parameters:
toplevelTOPLEVEL structure to emit notifications from.
objectOBJECT structure to emit notifications for.

Definition at line 751 of file o_basic.c.

void o_emit_change_notify ( TOPLEVEL toplevel,
OBJECT object 
)
Function Description
Calls each change callback function registered with TOPLEVEL to notify listeners that object has just been modified. All libgeda functions that modify OBJECT structures should call this just after making a change to an OBJECT.
Parameters:
toplevelTOPLEVEL structure to emit notifications from.
objectOBJECT structure to emit notifications for.

Definition at line 777 of file o_basic.c.

OBJECT* o_box_read ( TOPLEVEL toplevel,
const char  buf[],
unsigned int  release_ver,
unsigned int  fileformat_ver,
GError **  err 
)
Function Description
This function gets the description of a box from the *buf character string.

Depending on *version, the correct file format is considered. Currently two file format revisions are supported :

*
the file format used until 20000704 release
*
the file format used for the releases after 2000704.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]bufCharacter string with box description.
[in]release_verlibgeda release version number.
[in]fileformat_verlibgeda file format version number.
Returns:
The BOX OBJECT that was created, or NULL on error.

Note:
The old geda file format, i.e. releases 20000704 and older, does not handle the line type and the filling of the box object. They are set to default.
The current line format to describe a box is a space separated list of characters and numbers in plain ASCII on a single line. The meaning of each item is described in the file format documentation.
A box is internally described by its lower right and upper left corner whereas the line describe it with the lower left corner and the width and height.

A new object is allocated, initialized and added to the object list. Its filling and line type are set according to the values of the field on the line.

Definition at line 261 of file o_box_basic.c.

Here is the call graph for this function:

char* o_box_save ( TOPLEVEL toplevel,
OBJECT object 
)
Function Description
This function formats a string in the buffer *buff to describe the box object *object. It follows the post-20000704 release file format that handle the line type and fill options.
Parameters:
[in]toplevelThe TOPLEVEL structure.
[in]objectThe BOX OBJECT to create string from.
Returns:
A pointer to the BOX character string.
Warning:
Caller must g_free returned character string.

Note:
A box is internally represented by its lower right and upper left corner whereas it is described in the file format as its lower left corner and its width and height.

Definition at line 378 of file o_box_basic.c.

void o_box_print ( TOPLEVEL toplevel,
FILE *  fp,
OBJECT o_current,
int  origin_x,
int  origin_y 
)
Function Description
This function prints the box described by the o_current parameter to a Postscript document. It takes into account its line type and fill type. The Postscript document is descibed by the file pointer fp.

The validity of the o_current parameter is verified : a null pointer causes an error message and a return.

The description of the box is extracted from the o_current parameter : the coordinates of the box - upper left corner and width and height of the box -, its line type, its fill type.

The outline and the inside of the box are successively handled by two differend sets of functions.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]o_currentBOX OBJECT to write to document.
[in]origin_xPage x coordinate to place BOX OBJECT.
[in]origin_yPage y coordinate to place BOX OBJECT.

Note:
Depending on the type of the line for this particular box, the appropriate function is chosen among o_box_print_solid(), o_box_print_dotted(), o_box_print_dashed(), o_box_print_center() and o_box_print_phantom().

The needed parameters for each of these type is extracted from the o_current object. Depending on the type, unused parameters are set to -1.

In the eventuality of a length and/or space null, the line is printed solid to avoid and endless loop produced by other functions in such a case.

Note:
If the filling type of the box is not HOLLOW, the appropriate function is chosen among o_box_print_filled(), o_box_print_mesh() and o_box_print_hatch(). The corresponding parameters are extracted from the o_current object and corrected afterward.

The case where pitch1 and pitch2 are null or negative is avoided as it leads to an endless loop in most of the called functions. In such a case, the box is printed filled. Unused parameters for each of these functions are set to -1 or any passive value.

Definition at line 668 of file o_box_basic.c.

Here is the call graph for this function:

void o_box_print_solid ( TOPLEVEL toplevel,
FILE *  fp,
int  x,
int  y,
int  width,
int  height,
int  color,
int  line_width,
int  length,
int  space,
int  origin_x,
int  origin_y 
)
Function Description
This function prints the outline of a box when a solid line type is required. The box is defined by the coordinates of its upper left corner in (x,y) and its width and height given by the width and height parameters. The postscript file is defined by the file pointer fp. The parameters length and space are ignored.

It uses the function o_line_print_solid() to print the outline. It performs four calls to this function, one for each of its side.

All dimensions are in mils.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]xUpper x coordinate of BOX.
[in]yUpper y coordinate of BOX.
[in]widthWidth of BOX.
[in]heightHeight of BOX.
[in]colorBOX color.
[in]line_widthBOX Line width.
[in]lengthDashed line length.
[in]spaceAmount of space between dashes.
[in]origin_xPage x coordinate to place BOX OBJECT.
[in]origin_yPage y coordinate to place BOX OBJECT.

Definition at line 848 of file o_box_basic.c.

Here is the call graph for this function:

void o_box_print_dotted ( TOPLEVEL toplevel,
FILE *  fp,
int  x,
int  y,
int  width,
int  height,
int  color,
int  line_width,
int  length,
int  space,
int  origin_x,
int  origin_y 
)
Function Description
This function prints the outline of a box when a dotted line type is required. The box is defined by the coordinates of its upper left corner in (x,y) and its width and height given by the width and height parameters. The postscript file is defined by the file pointer fp. The parameters length is ignored.

It uses the function o_line_print_dotted() to print the outline. It performs four calls to this function, one for each of its side.

All dimensions are in mils.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]xUpper x coordinate of BOX.
[in]yUpper y coordinate of BOX.
[in]widthWidth of BOX.
[in]heightHeight of BOX.
[in]colorBOX color.
[in]line_widthBOX Line width.
[in]lengthDashed line length.
[in]spaceAmount of space between dashes.
[in]origin_xPage x coordinate to place BOX OBJECT.
[in]origin_yPage y coordinate to place BOX OBJECT.

Definition at line 911 of file o_box_basic.c.

Here is the call graph for this function:

void o_box_print_dashed ( TOPLEVEL toplevel,
FILE *  fp,
int  x,
int  y,
int  width,
int  height,
int  color,
int  line_width,
int  length,
int  space,
int  origin_x,
int  origin_y 
)
Function Description
This function prints the outline of a box when a dashed line type is required. The box is defined by the coordinates of its upper left corner in (x,y) and its width and height given by the width and height parameters. The postscript file is defined by the file pointer fp.

It uses the function o_line_print_dashed() to print the outline. It performs four calls to this function, one for each of its side.

All dimensions are in mils.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]xUpper x coordinate of BOX.
[in]yUpper y coordinate of BOX.
[in]widthWidth of BOX.
[in]heightHeight of BOX.
[in]colorBOX color.
[in]line_widthBOX Line width.
[in]lengthDashed line length.
[in]spaceAmount of space between dashes.
[in]origin_xPage x coordinate to place BOX OBJECT.
[in]origin_yPage y coordinate to place BOX OBJECT.

Definition at line 973 of file o_box_basic.c.

Here is the call graph for this function:

void o_box_print_center ( TOPLEVEL toplevel,
FILE *  fp,
int  x,
int  y,
int  width,
int  height,
int  color,
int  line_width,
int  length,
int  space,
int  origin_x,
int  origin_y 
)
Function Description
This function prints the outline of a box when a centered line type is required. The box is defined by the coordinates of its upper left corner in (x,y) and its width and height given by the width and height parameters. The postscript file is defined by the file pointer fp.

It uses the function o_line_print_center() to print the outline. It performs four calls to this function, one for each of its side.

All dimensions are in mils.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]xUpper x coordinate of BOX.
[in]yUpper y coordinate of BOX.
[in]widthWidth of BOX.
[in]heightHeight of BOX.
[in]colorBOX color.
[in]line_widthBOX Line width.
[in]lengthDashed line length.
[in]spaceAmount of space between dashes.
[in]origin_xPage x coordinate to place BOX OBJECT.
[in]origin_yPage y coordinate to place BOX OBJECT.

Definition at line 1036 of file o_box_basic.c.

Here is the call graph for this function:

void o_box_print_phantom ( TOPLEVEL toplevel,
FILE *  fp,
int  x,
int  y,
int  width,
int  height,
int  color,
int  line_width,
int  length,
int  space,
int  origin_x,
int  origin_y 
)
Function Description
This function prints the outline of a box when a phantom line type is required. The box is defined by the coordinates of its upper left corner in (x,y) and its width and height given by the width and height parameters. The postscript file is defined by the file pointer fp.

It uses the function o_line_print_phantom() to print the outline. It performs four calls to this function, one for each of its side.

All dimensions are in mils.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]xUpper x coordinate of BOX.
[in]yUpper y coordinate of BOX.
[in]widthWidth of BOX.
[in]heightHeight of BOX.
[in]colorBOX color.
[in]line_widthBOX Line width.
[in]lengthDashed line length.
[in]spaceAmount of space between dashes.
[in]origin_xPage x coordinate to place BOX OBJECT.
[in]origin_yPage y coordinate to place BOX OBJECT.

Definition at line 1098 of file o_box_basic.c.

Here is the call graph for this function:

void o_box_print_filled ( TOPLEVEL toplevel,
FILE *  fp,
int  x,
int  y,
int  width,
int  height,
int  color,
int  fill_width,
int  angle1,
int  pitch1,
int  angle2,
int  pitch2,
int  origin_x,
int  origin_y 
)
Function Description
The function prints a filled box with a solid pattern. No outline is printed. The box is defined by the coordinates of its upper left corner in (x,y) and its width and height given by the width and height parameters. The postscript file is defined by the file pointer fp. fill_width, angle1 and pitch1, angle2 and pitch2 parameters are ignored in this functions but kept for compatibility with other fill functions.

It uses the fbox postscript function defined in the prolog to specify a filled box.

All dimensions are in mils.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]xUpper x coordinate of BOX.
[in]yUpper y coordinate of BOX.
[in]widthWidth of BOX.
[in]heightHeight of BOX.
[in]colorBOX color.
[in]fill_widthBOX fill width. (unused).
[in]angle1(unused).
[in]pitch1(unused).
[in]angle2(unused).
[in]pitch2(unused).
[in]origin_xPage x coordinate to place BOX OBJECT.
[in]origin_yPage y coordinate to place BOX OBJECT.

Definition at line 1166 of file o_box_basic.c.

Here is the call graph for this function:

void o_box_print_mesh ( TOPLEVEL toplevel,
FILE *  fp,
int  x,
int  y,
int  width,
int  height,
int  color,
int  fill_width,
int  angle1,
int  pitch1,
int  angle2,
int  pitch2,
int  origin_x,
int  origin_y 
)
Function Description
This function prints a meshed box. No outline is printed. The box is defined by the coordinates of its upper left corner in (x,y) and its width and height given by the width and height parameters. The postscript file is defined by the file pointer fp.

The inside mesh is achieved by two successive call to the o_box_print_hatch() function, given angle1 and pitch1 the first time and angle2 and pitch2 the second time.

Negative or null values for pitch1 and/or pitch2 are not allowed as it leads to an endless loop in o_box_print_hatch().

All dimensions are in mils.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]xUpper x coordinate of BOX.
[in]yUpper y coordinate of BOX.
[in]widthWidth of BOX.
[in]heightHeight of BOX.
[in]colorBOX color.
[in]fill_widthBOX fill width.
[in]angle11st angle for mesh pattern.
[in]pitch11st pitch for mesh pattern.
[in]angle22nd angle for mesh pattern.
[in]pitch22nd pitch for mesh pattern.
[in]origin_xPage x coordinate to place BOX OBJECT.
[in]origin_yPage y coordinate to place BOX OBJECT.

Definition at line 1218 of file o_box_basic.c.

Here is the call graph for this function:

void o_box_print_hatch ( TOPLEVEL toplevel,
FILE *  fp,
int  x,
int  y,
int  width,
int  height,
int  color,
int  fill_width,
int  angle1,
int  pitch1,
int  angle2,
int  pitch2,
int  origin_x,
int  origin_y 
)
Function Description
The function prints a hatched box. No outline is printed. The box is defined by the coordinates of its upper left corner in (x,y) and its width and height given by the width and height parameters. The postscript file is defined by the file pointer fp. fill_width, angle1, pitch1 parameters define the way the box has to be hatched. angle2 and pitch2 parameters are unused but kept for compatibility with other fill functions.

Negative or null values for pitch1 are not allowed as it leads to an endless loop.

All dimensions are in mils.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]xUpper x coordinate of BOX.
[in]yUpper y coordinate of BOX.
[in]widthWidth of BOX.
[in]heightHeight of BOX.
[in]colorBOX color.
[in]fill_widthBOX fill width.
[in]angle1Angle of hatch pattern.
[in]pitch1Pitch of hatch pattern.
[in]angle2(unused).
[in]pitch2(unused).
[in]origin_xPage x coordinate to place BOX OBJECT.
[in]origin_yPage y coordinate to place BOX OBJECT.

Definition at line 1273 of file o_box_basic.c.

Here is the call graph for this function:

double o_box_shortest_distance ( OBJECT object,
int  x,
int  y,
int  force_solid 
)
Parameters:
[in]objectThe box OBJECT.
[in]xThe x coordinate of the given point.
[in]yThe y coordinate of the given point.
[in]force_solidIf true, force treating the object as solid.
Returns:
The shortest distance from the object to the point. With an invalid parameter, this function returns G_MAXDOUBLE.

Definition at line 1325 of file o_box_basic.c.

Here is the call graph for this function:

void world_get_box_bounds ( TOPLEVEL toplevel,
OBJECT object,
int *  left,
int *  top,
int *  right,
int *  bottom 
)
Function Description
This function sets the left, top, right and bottom parameters to the boundings of the box object described in *box in world units.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]objectBOX OBJECT to read coordinates from.
[out]leftLeft box coordinate in WORLD units.
[out]topTop box coordinate in WORLD units.
[out]rightRight box coordinate in WORLD units.
[out]bottomBottom box coordinate in WORLD units.

Definition at line 607 of file o_box_basic.c.

gboolean o_box_get_position ( TOPLEVEL toplevel,
gint *  x,
gint *  y,
OBJECT object 
)
Function Description
This function gets the position of the bottom left point of a box object.
Parameters:
[in]toplevelThe toplevel environment.
[out]xpointer to the x-position
[out]ypointer to the y-position
[in]objectThe object to get the position.
Returns:
TRUE if successfully determined the position, FALSE otherwise

Definition at line 636 of file o_box_basic.c.

void o_box_recalc ( TOPLEVEL toplevel,
OBJECT o_current 
)
Function Description
This function recalculates the box coordinates and its bounding are recalculated as well.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in,out]o_currentBOX OBJECT to be recalculated.

Definition at line 577 of file o_box_basic.c.

Here is the call graph for this function:

OBJECT* o_bus_read ( TOPLEVEL toplevel,
const char  buf[],
unsigned int  release_ver,
unsigned int  fileformat_ver,
GError **  err 
)
Function Description
This function reads a bus object from the buffer buf. If the bus object was read successfully, a new bus object is allocated and appended to the object_list.
Parameters:
[in]toplevelThe TOPLEVEL object
[in]bufa text buffer (usually a line of a schematic file)
[in]release_verThe release number gEDA
[in]fileformat_vera integer value of the file format
Returns:
The object list, or NULL on error.

Definition at line 148 of file o_bus_basic.c.

Here is the call graph for this function:

char* o_bus_save ( TOPLEVEL toplevel,
OBJECT object 
)
Function Description
This function takes a bus object and return a string according to the file format definition.
Parameters:
[in]toplevela TOPLEVEL structure
[in]objecta bus OBJECT
Returns:
the string representation of the bus OBJECT

Definition at line 207 of file o_bus_basic.c.

void o_bus_print ( TOPLEVEL toplevel,
FILE *  fp,
OBJECT o_current,
int  origin_x,
int  origin_y 
)
Function Description
This function writes the postscript command of the bus object o_current into the FILE fp points to.
Parameters:
[in]toplevelThe TOPLEVEL object
[in]fppointer to a FILE structure
[in]o_currentThe OBJECT to print
[in]origin_xx-coord of the postscript origin
[in]origin_yy-coord of the postscript origin

Definition at line 280 of file o_bus_basic.c.

Here is the call graph for this function:

void world_get_bus_bounds ( TOPLEVEL toplevel,
OBJECT object,
int *  left,
int *  top,
int *  right,
int *  bottom 
)
Function Description
This function calculates the object boudaries of a bus object.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]objecta bus object
[out]leftthe left world coord
[out]topthe top world coord
[out]rightthe right world coord
[out]bottomthe bottom world coord

Definition at line 62 of file o_bus_basic.c.

Here is the call graph for this function:

gboolean o_bus_get_position ( TOPLEVEL toplevel,
gint *  x,
gint *  y,
OBJECT object 
)
Function Description
This function gets the position of the first point of a bus object.
Parameters:
[in]toplevelThe toplevel environment.
[out]xpointer to the x-position
[out]ypointer to the y-position
[in]objectThe object to get the position.
Returns:
TRUE if successfully determined the position, FALSE otherwise

Definition at line 45 of file o_bus_basic.c.

Here is the call graph for this function:

void o_bus_recalc ( TOPLEVEL toplevel,
OBJECT o_current 
)
Function Description
This function updates the visual coords of the o_current object.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]o_currenta bus object.

Definition at line 115 of file o_bus_basic.c.

Here is the call graph for this function:

OBJECT* o_circle_read ( TOPLEVEL toplevel,
const char  buf[],
unsigned int  release_ver,
unsigned int  fileformat_ver,
GError **  err 
)
Function Description
The o_circle_read() function gets from the character string *buff the description of a circle.

Depending on *version, the right file format is considered. Currently two file format revisions are supported :

*
the file format used until 2000704 release.
*
the file format used for the releases after 20000704.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]bufCharacter string with circle description.
[in]release_verlibgeda release version number.
[in]fileformat_verlibgeda file format version number.
Returns:
A pointer to the new circle object, or NULL on error.

Definition at line 225 of file o_circle_basic.c.

Here is the call graph for this function:

char* o_circle_save ( TOPLEVEL toplevel,
OBJECT object 
)
Function Description
This function formats a string in the buffer *buff to describe the circle object *object. It follows the post-20000704 release file format that handle the line type and fill options.
Parameters:
[in]toplevela TOPLEVEL structure.
[in]objectCircle OBJECT to create string from.
Returns:
A pointer to the circle OBJECT character string.
Note:
Caller must g_free returned character string.

Definition at line 326 of file o_circle_basic.c.

void o_circle_print ( TOPLEVEL toplevel,
FILE *  fp,
OBJECT o_current,
int  origin_x,
int  origin_y 
)
Function Description
This function prints the circle described by the o_current parameter to a Postscript document. It takes into account its line type and fill type. The Postscript document is descibed by the file pointer fp.

The validity of the o_current pointer is checked : a null pointer causes an error message and a return.

The description of the circle is extracted from the o_current parameter : the coordinates of the center of the circle, its radius, its line type, its fill type.

The outline and the inside of the circle are successively handled by two differend sets of functions.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]o_currentCircle OBJECT to write to document.
[in]origin_xPage x coordinate to place circle OBJECT.
[in]origin_yPage y coordinate to place circle OBJECT.

Definition at line 576 of file o_circle_basic.c.

Here is the call graph for this function:

void o_circle_print_solid ( TOPLEVEL toplevel,
FILE *  fp,
int  x,
int  y,
int  radius,
int  color,
int  circle_width,
int  length,
int  space,
int  origin_x,
int  origin_y 
)
Function Description
This function prints the outline of a circle when a solid line type is required. The circle is defined by its center in (x, y) and its radius in radius. It is printed with the color given in color. The parameters length and space are ignored.

It uses the function o_arc_print_solid() to print the outline. Therefore it acts as an interface between the way a circle is defined and the way an arc is defined.

All dimensions are in mils.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]xCenter x coordinate of circle.
[in]yCenter y coordinate of circle.
[in]radiusCircle radius.
[in]colorCircle color.
[in]circle_widthWidth of circle.
[in]length(unused).
[in]space(unused).
[in]origin_xPage x coordinate to place circle OBJECT.
[in]origin_yPage y coordinate to place circle OBJECT.

Definition at line 753 of file o_circle_basic.c.

Here is the call graph for this function:

void o_circle_print_dotted ( TOPLEVEL toplevel,
FILE *  fp,
int  x,
int  y,
int  radius,
int  color,
int  circle_width,
int  length,
int  space,
int  origin_x,
int  origin_y 
)
Function Description
This function prints the outline of a circle when a dotted line type is required. The circle is defined by its center in (x, y) and its radius in radius. It is printed with the color given in color. The parameter length is ignored.

It uses the function o_arc_print_dotted() to print the outline. Therefore it acts as an interface between the way a circle is defined and the way an arc is defined.

All dimensions are in mils.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]xCenter x coordinate of circle.
[in]yCenter y coordinate of circle.
[in]radiusCircle radius.
[in]colorCircle color.
[in]circle_widthWidth of circle.
[in]length(unused).
[in]spaceSpace between dots.
[in]origin_xPage x coordinate to place circle OBJECT.
[in]origin_yPage y coordinate to place circle OBJECT.

Definition at line 796 of file o_circle_basic.c.

Here is the call graph for this function:

void o_circle_print_dashed ( TOPLEVEL toplevel,
FILE *  fp,
int  x,
int  y,
int  radius,
int  color,
int  circle_width,
int  length,
int  space,
int  origin_x,
int  origin_y 
)
Function Description
This function prints the outline of a circle when a dashed line type is required. The circle is defined by its center in (x, y) and its radius in radius. It is printed with the color given in color.

It uses the function o_arc_print_dashed() to print the outline. Therefore it acts as an interface between the way a circle is defined and the way an arc is defined.

All dimensions are in mils.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]xCenter x coordinate of circle.
[in]yCenter y coordinate of circle.
[in]radiusCircle radius.
[in]colorCircle color.
[in]circle_widthWidth of circle.
[in]lengthLength of dashed lines.
[in]spaceSpace between dashes.
[in]origin_xPage x coordinate to place circle OBJECT.
[in]origin_yPage y coordinate to place circle OBJECT.

Definition at line 837 of file o_circle_basic.c.

Here is the call graph for this function:

void o_circle_print_center ( TOPLEVEL toplevel,
FILE *  fp,
int  x,
int  y,
int  radius,
int  color,
int  circle_width,
int  length,
int  space,
int  origin_x,
int  origin_y 
)
Function Description
This function prints the outline of a circle when a centered line type is required. The circle is defined by its center in (x, y) and its radius in radius. It is printed with the color given in color.

It uses the function o_arc_print_center() to print the outline. Therefore it acts as an interface between the way a circle is defined and the way an arc is defined.

All dimensions are in mils.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]xCenter x coordinate of circle.
[in]yCenter y coordinate of circle.
[in]radiusCircle radius.
[in]colorCircle color.
[in]circle_widthWidth of circle.
[in]lengthLength of dashed lines.
[in]spaceSpace between dashes.
[in]origin_xPage x coordinate to place circle OBJECT.
[in]origin_yPage y coordinate to place circle OBJECT.

Definition at line 879 of file o_circle_basic.c.

Here is the call graph for this function:

void o_circle_print_phantom ( TOPLEVEL toplevel,
FILE *  fp,
int  x,
int  y,
int  radius,
int  color,
int  circle_width,
int  length,
int  space,
int  origin_x,
int  origin_y 
)
Function Description
This function prints the outline of a circle when a phantom line type is required. The circle is defined by its center in (x, y) and its radius in radius. It is printed with the color given in color.

It uses the function o_arc_print_phantom() to print the outline. Therefore it acts as an interface between the way a circle is defined and the way an arc is defined.

All dimensions are in mils.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]xCenter x coordinate of circle.
[in]yCenter y coordinate of circle.
[in]radiusCircle radius.
[in]colorCircle color.
[in]circle_widthWidth of circle.
[in]lengthLength of dashed lines.
[in]spaceSpace between dashes.
[in]origin_xPage x coordinate to place circle OBJECT.
[in]origin_yPage y coordinate to place circle OBJECT.

Definition at line 921 of file o_circle_basic.c.

Here is the call graph for this function:

void o_circle_print_filled ( TOPLEVEL toplevel,
FILE *  fp,
int  x,
int  y,
int  radius,
int  color,
int  fill_width,
int  angle1,
int  pitch1,
int  angle2,
int  pitch2,
int  origin_x,
int  origin_y 
)
Function Description
The function prints a filled circle with a solid pattern. No outline is printed. The circle is defined by the coordinates of its center in (x,y) and its radius given by the radius parameter. The postscript file is defined by the file pointer fp. fill_width, angle1 and pitch1, angle2 and pitch2 parameters are ignored in this functions but kept for compatibility with other fill functions.

All dimensions are in mils (except angle1 and angle2 in degree).

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]xCenter x coordinate of circle.
[in]yCenter y coordinate of circle.
[in]radiusRadius of circle.
[in]colorCircle color.
[in]fill_widthCircle fill width. (unused).
[in]angle1(unused).
[in]pitch1(unused).
[in]angle2(unused).
[in]pitch2(unused).
[in]origin_xPage x coordinate to place circle OBJECT.
[in]origin_yPage y coordinate to place circle OBJECT.

Definition at line 965 of file o_circle_basic.c.

Here is the call graph for this function:

void o_circle_print_mesh ( TOPLEVEL toplevel,
FILE *  fp,
int  x,
int  y,
int  radius,
int  color,
int  fill_width,
int  angle1,
int  pitch1,
int  angle2,
int  pitch2,
int  origin_x,
int  origin_y 
)
Function Description
This function prints a meshed circle. No outline is printed. The circle is defined by the coordinates of its center in (x,y) and its radius by the radius parameter. The Postscript document is defined by the file pointer fp.

The inside mesh is achieved by two successive call to the o_circle_print_hatch() function, given angle1 and pitch1 the first time and angle2 and pitch2 the second time.

Negative or null values for pitch1 and/or pitch2 are not allowed as it leads to an endless loop in o_circle_print_hatch().

All dimensions are in mils (except angle1 and angle2 in degree).

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]xCenter x coordinate of circle.
[in]yCenter y coordinate of circle.
[in]radiusRadius of circle.
[in]colorCircle color.
[in]fill_widthCircle fill width.
[in]angle11st angle for mesh pattern.
[in]pitch11st pitch for mesh pattern.
[in]angle22nd angle for mesh pattern.
[in]pitch22nd pitch for mesh pattern.
[in]origin_xPage x coordinate to place circle OBJECT.
[in]origin_yPage y coordinate to place circle OBJECT.

Definition at line 1011 of file o_circle_basic.c.

Here is the call graph for this function:

void o_circle_print_hatch ( TOPLEVEL toplevel,
FILE *  fp,
int  x,
int  y,
int  radius,
int  color,
int  fill_width,
int  angle1,
int  pitch1,
int  angle2,
int  pitch2,
int  origin_x,
int  origin_y 
)
Function Description
The function prints a hatched circle. No outline is printed. The circle is defined by the coordinates of its center in (x,y) and its radius by the radius parameter. The Postscript document is defined by the file pointer fp. angle2 and pitch2 parameters are ignored in this functions but kept for compatibility with other fill functions.

The only attribute of line here is its width from the parameter width.

Negative or null values for pitch1 is not allowed as it leads to an endless loop.

All dimensions are in mils (except angle1 is in degrees).

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]xCenter x coordinate of circle.
[in]yCenter y coordinate of circle.
[in]radiusRadius of circle.
[in]colorCircle color.
[in]fill_widthCircle fill width.
[in]angle1Angle for hatch pattern.
[in]pitch1Pitch for hatch pattern.
[in]angle2(unused).
[in]pitch2(unused).
[in]origin_xPage x coordinate to place circle OBJECT.
[in]origin_yPage y coordinate to place circle OBJECT.

Definition at line 1066 of file o_circle_basic.c.

Here is the call graph for this function:

double o_circle_shortest_distance ( OBJECT object,
int  x,
int  y,
int  force_solid 
)
Parameters:
[in]objectThe circle OBJECT.
[in]xThe x coordinate of the given point.
[in]yThe y coordinate of the given point.
[in]force_solidIf true, force treating the object as solid.
Returns:
The shortest distance from the object to the point. With an invalid parameter, this function returns G_MAXDOUBLE.

Definition at line 1116 of file o_circle_basic.c.

Here is the call graph for this function:

void world_get_circle_bounds ( TOPLEVEL toplevel,
OBJECT object,
int *  left,
int *  top,
int *  right,
int *  bottom 
)
Function Description
This function sets the left, top, right and bottom parameters to the boundings of the circle object described in *circle in world units.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]objectCircle OBJECT to read coordinates from.
[out]leftLeft circle coordinate in WORLD units.
[out]topTop circle coordinate in WORLD units.
[out]rightRight circle coordinate in WORLD units.
[out]bottomBottom circle coordinate in WORLD units.

Definition at line 515 of file o_circle_basic.c.

gboolean o_circle_get_position ( TOPLEVEL toplevel,
gint *  x,
gint *  y,
OBJECT object 
)
Function Description
This function gets the position of the center point of a circle object.
Parameters:
[in]toplevelThe toplevel environment.
[out]xpointer to the x-position
[out]ypointer to the y-position
[in]objectThe object to get the position.
Returns:
TRUE if successfully determined the position, FALSE otherwise

Definition at line 545 of file o_circle_basic.c.

void o_circle_recalc ( TOPLEVEL toplevel,
OBJECT o_current 
)
Function Description
This function recalculates the screen coords of the o_current pointed circle object from its world coords.

The circle coordinates and its bounding are recalculated as well as the OBJECT specific (line width, filling ...).

Parameters:
[in]toplevelThe TOPLEVEL object.
[in,out]o_currentCircle OBJECT to be recalculated.

Definition at line 484 of file o_circle_basic.c.

Here is the call graph for this function:

OBJECT* o_complex_read ( TOPLEVEL toplevel,
const char  buf[],
unsigned int  release_ver,
unsigned int  fileformat_ver,
GError **  err 
)
Function Description
This function reads a complex object from the buffer buf. If the complex object was read successfully, a new object is allocated and appended to the object_list.
Parameters:
[in]toplevelThe TOPLEVEL object
[in]bufa text buffer (usually a line of a schematic file)
[in]release_verThe release number gEDA
[in]fileformat_vera integer value of the file format
Returns:
The object list, or NULL on error.

Definition at line 638 of file o_complex_basic.c.

Here is the call graph for this function:

char* o_complex_save ( TOPLEVEL toplevel,
OBJECT object 
)
Function Description
This function takes a complex object and return a string according to the file format definition.
Parameters:
[in]toplevela TOPLEVEL structure
[in]objecta complex OBJECT
Returns:
the string representation of the complex OBJECT

Definition at line 718 of file o_complex_basic.c.

double o_complex_shortest_distance ( OBJECT object,
int  x,
int  y,
int  force_solid 
)
Note:
When querying the distance to our child objects, we always force treating them as solid filled. We ignore the force_solid argument to this function.
Parameters:
[in]objectThe complex OBJECT.
[in]xThe x coordinate of the given point.
[in]yThe y coordinate of the given point.
[in]force_solidIf true, force treating the object as solid.
Returns:
The shortest distance from the object to the point. If the distance cannot be calculated, this function returns a really large number (G_MAXDOUBLE). With an invalid parameter, this function returns G_MAXDOUBLE.

Definition at line 1141 of file o_complex_basic.c.

Here is the call graph for this function:

void world_get_complex_bounds ( TOPLEVEL toplevel,
OBJECT complex,
int *  left,
int *  top,
int *  right,
int *  bottom 
)
Function Description
This function returns the bounding box of the complex object object.
Parameters:
[in]toplevelThe toplevel environment.
[in]complexThe complex object.
[out]leftThe leftmost edge of the bounding box (in world units).
[out]topThe upper edge of the bounding box (in world units).
[out]rightThe rightmost edge of the bounding box (in world units).
[out]bottomThe bottom edge of the bounding box (in screen units).

Definition at line 165 of file o_complex_basic.c.

Here is the call graph for this function:

gboolean o_complex_get_position ( TOPLEVEL toplevel,
gint *  x,
gint *  y,
OBJECT object 
)
Function Description
This function gets the position of the base point of a complex object.
Parameters:
[in]toplevelThe toplevel environment.
[out]xpointer to the x-position
[out]ypointer to the y-position
[in]objectThe object to get the position.
Returns:
TRUE if successfully determined the position, FALSE otherwise

Definition at line 187 of file o_complex_basic.c.

void o_complex_recalc ( TOPLEVEL toplevel,
OBJECT o_current 
)
Function Description
This function updates the boundaries of the object o_current.
Parameters:
[in]toplevelThe TOPLEVEL object
[in]o_currentThe OBJECT to update

Definition at line 604 of file o_complex_basic.c.

Here is the call graph for this function:

GList* o_complex_get_promotable ( TOPLEVEL toplevel,
OBJECT object,
int  detach 
)
Function Description
Returns a GList of OBJECTs which are eligible for promotion from within the passed complex OBJECT.

If detach is TRUE, the function removes these attribute objects from the prim_objs of the complex. If detach is FALSE, the OBJECTs are left in place.

Parameters:
[in]toplevelThe toplevel environment.
[in]objectThe complex object being modified.
[in]detachShould the attributes be detached?
Returns:
A linked list of OBJECTs to promote.

Definition at line 275 of file o_complex_basic.c.

Here is the call graph for this function:

OBJECT* o_line_read ( TOPLEVEL toplevel,
const char  buf[],
unsigned int  release_ver,
unsigned int  fileformat_ver,
GError **  err 
)
Function Description
This function creates a line OBJECT from the character string *buf the description of a box.

The function returns a pointer on the new last element, that is the added line object.

Depending on *version, the correct file format is considered. Currently two file format revisions are supported :

*
the file format used until 20010704 release.
*
the file format used for the releases after 20010704.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]bufCharacter string with line description.
[in]release_verlibgeda release version number.
[in]fileformat_verlibgeda file format version number.
Returns:
A pointer to the new line object, or NULL on error.

Definition at line 209 of file o_line_basic.c.

Here is the call graph for this function:

char* o_line_save ( TOPLEVEL toplevel,
OBJECT object 
)
Function Description
The function formats a string in the buffer *buff to describe the box object *object. It follows the post-20000704 release file format that handle the line type and fill options - filling is irrelevant here.
Parameters:
[in]toplevela TOPLEVEL structure.
[in]objectLine OBJECT to create string from.
Returns:
A pointer to the line OBJECT character string.
Note:
Caller must g_free returned character string.

Definition at line 302 of file o_line_basic.c.

void o_line_print ( TOPLEVEL toplevel,
FILE *  fp,
OBJECT o_current,
int  origin_x,
int  origin_y 
)
Function Description
This function prints the line described by the o_current parameter to a Postscript document. The Postscript document is described by the fp file pointer.

Parameters of the line are extracted from object pointed by o_current.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]o_currentLine OBJECT to write to document.
[in]origin_xPage x coordinate to place line OBJECT.
[in]origin_yPage y coordinate to place line OBJECT.

Definition at line 528 of file o_line_basic.c.

Here is the call graph for this function:

void o_line_print_solid ( TOPLEVEL toplevel,
FILE *  fp,
int  x1,
int  y1,
int  x2,
int  y2,
int  color,
int  line_width,
int  length,
int  space,
int  origin_x,
int  origin_y 
)
Function Description
This function prints a line when a solid line type is required. The line is defined by the coordinates of its two ends in (x1,y1) and (x2,y2). The Postscript document is defined by the file pointer fp. The parameters length and space are ignored whereas line_width specifies the width of the printed line.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]x1Upper x coordinate.
[in]y1Upper y coordinate.
[in]x2Lower x coordinate.
[in]y2Lower y coordinate.
[in]colorLine color.
[in]line_widthWidth of line.
[in]length(unused).
[in]space(unused).
[in]origin_xPage x coordinate to place line OBJECT.
[in]origin_yPage y coordinate to place line OBJECT.

Definition at line 637 of file o_line_basic.c.

Here is the call graph for this function:

void o_line_print_dotted ( TOPLEVEL toplevel,
FILE *  fp,
int  x1,
int  y1,
int  x2,
int  y2,
int  color,
int  line_width,
int  length,
int  space,
int  origin_x,
int  origin_y 
)
Function Description
This function prints a line when a dotted line type is required. The line is defined by the coordinates of its two ends in (x1,y1) and (x2,y2). The Postscript document is defined by the file pointer fp. The parameter length is ignored whereas line_width specifies the diameter of the dots and space the distance between two dots.

A negative value for space leads to an endless loop.

All dimensions are in mils.

The function sets the color in which the line will be printed with.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]x1Upper x coordinate.
[in]y1Upper y coordinate.
[in]x2Lower x coordinate.
[in]y2Lower y coordinate.
[in]colorLine color.
[in]line_widthWidth of line.
[in]length(unused).
[in]spaceSpace between dots.
[in]origin_xPage x coordinate to place line OBJECT.
[in]origin_yPage y coordinate to place line OBJECT.

Definition at line 678 of file o_line_basic.c.

Here is the call graph for this function:

void o_line_print_dashed ( TOPLEVEL toplevel,
FILE *  fp,
int  x1,
int  y1,
int  x2,
int  y2,
int  color,
int  line_width,
int  length,
int  space,
int  origin_x,
int  origin_y 
)
Function Description
This function prints a line when a dashed line type is required. The line is defined by the coordinates of its two ends in (x1,y1) and (x2,y2). The postscript file is defined by the file pointer fp.

A negative value for space or length leads to an endless loop.

All dimensions are in mils.

The function sets the color in which the line will be printed and the width of the line - that is the width of the dashes.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]x1Upper x coordinate.
[in]y1Upper y coordinate.
[in]x2Lower x coordinate.
[in]y2Lower y coordinate.
[in]colorLine color.
[in]line_widthWidth of line.
[in]lengthLength of a dash.
[in]spaceSpace between dashes.
[in]origin_xPage x coordinate to place line OBJECT.
[in]origin_yPage y coordinate to place line OBJECT.

Definition at line 759 of file o_line_basic.c.

Here is the call graph for this function:

void o_line_print_center ( TOPLEVEL toplevel,
FILE *  fp,
int  x1,
int  y1,
int  x2,
int  y2,
int  color,
int  line_width,
int  length,
int  space,
int  origin_x,
int  origin_y 
)
Function Description
This function prints a line when a centered line type is required. The line is defined by the coordinates of its two ends in (x1,y1) and (x2,y2). The Postscript document is defined by the file pointer fp.

A negative value for space or length leads to an endless loop.

All dimensions are in mils.

The function sets the color in which the line will be printed and the width of the line - that is the width of the dashes and the diameter of the dots.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]x1Upper x coordinate.
[in]y1Upper y coordinate.
[in]x2Lower x coordinate.
[in]y2Lower y coordinate.
[in]colorLine color.
[in]line_widthWidth of line.
[in]lengthLength of a dash.
[in]spaceSpace between dashes.
[in]origin_xPage x coordinate to place line OBJECT.
[in]origin_yPage y coordinate to place line OBJECT.

Definition at line 862 of file o_line_basic.c.

Here is the call graph for this function:

void o_line_print_phantom ( TOPLEVEL toplevel,
FILE *  fp,
int  x1,
int  y1,
int  x2,
int  y2,
int  color,
int  line_width,
int  length,
int  space,
int  origin_x,
int  origin_y 
)
Function Description
This function prints a line when a phantom line type is required. The line is defined by the coordinates of its two ends in (x1,y1) and (x2,y2). The Postscript document is defined by the file pointer fp.

A negative value for space or length leads to an endless loop.

All dimensions are in mils.

The function sets the color in which the line will be printed and the width of the line - that is the width of the dashes and the diameter of the dots.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]x1Upper x coordinate.
[in]y1Upper y coordinate.
[in]x2Lower x coordinate.
[in]y2Lower y coordinate.
[in]colorLine color.
[in]line_widthWidth of line.
[in]lengthLength of a dash.
[in]spaceSpace between dashes.
[in]origin_xPage x coordinate to place line OBJECT.
[in]origin_yPage y coordinate to place line OBJECT.

Definition at line 994 of file o_line_basic.c.

Here is the call graph for this function:

double o_line_shortest_distance ( OBJECT object,
int  x,
int  y,
int  force_solid 
)

If the closest point on the line resides beyond the line segment's end point, this function returns the distance from the given point to the closest end point.

If the line represents a single point (the endpoints are the same), this function calcualtes the distance to that point.

Parameters:
[in]objectThe line OBJECT.
[in]xThe x coordinate of the given point.
[in]yThe y coordinate of the given point.
[in]force_solidIf true, force treating the object as solid.
Returns:
The shortest distance from the object to the point. With an invalid parameter, this function returns G_MAXDOUBLE.

Definition at line 1187 of file o_line_basic.c.

Here is the call graph for this function:

void world_get_line_bounds ( TOPLEVEL toplevel,
OBJECT object,
int *  left,
int *  top,
int *  right,
int *  bottom 
)
Function Description
This function sets the left, top, right and bottom parameters to the boundings of the line object described in *line in world units.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]objectLine OBJECT to read coordinates from.
[out]leftLeft line coordinate in WORLD units.
[out]topTop line coordinate in WORLD units.
[out]rightRight line coordinate in WORLD units.
[out]bottomBottom line coordinate in WORLD units.

Definition at line 475 of file o_line_basic.c.

gboolean o_line_get_position ( TOPLEVEL toplevel,
gint *  x,
gint *  y,
OBJECT object 
)
Function Description
This function gets the position of the first point of a line object.
Parameters:
[in]toplevelThe toplevel environment.
[out]xpointer to the x-position
[out]ypointer to the y-position
[in]objectThe object to get the position.
Returns:
TRUE if successfully determined the position, FALSE otherwise

Definition at line 504 of file o_line_basic.c.

void o_line_recalc ( TOPLEVEL toplevel,
OBJECT o_current 
)
Function Description
This function recalculate the bounding box of the o_current
Parameters:
[in]toplevelThe TOPLEVEL object.
[in,out]o_currentLine OBJECT to be recalculated.

Definition at line 444 of file o_line_basic.c.

Here is the call graph for this function:

OBJECT* o_net_read ( TOPLEVEL toplevel,
const char  buf[],
unsigned int  release_ver,
unsigned int  fileformat_ver,
GError **  err 
)
Function Description
This function reads a net object from the buffer buf. If the netobject was read successfully, a new net object is allocated and appended to the object_list.
Parameters:
[in]toplevelThe TOPLEVEL object
[in]bufa text buffer (usually a line of a schematic file)
[in]release_verThe release number gEDA
[in]fileformat_vera integer value of the file format
Returns:
The object list, or NULL on error.

Definition at line 146 of file o_net_basic.c.

Here is the call graph for this function:

char* o_net_save ( TOPLEVEL toplevel,
OBJECT object 
)
Function Description
This function takes a net object and return a string according to the file format definition.
Parameters:
[in]toplevela TOPLEVEL structure
[in]objecta net OBJECT
Returns:
the string representation of the net OBJECT

Definition at line 190 of file o_net_basic.c.

void o_net_print ( TOPLEVEL toplevel,
FILE *  fp,
OBJECT o_current,
int  origin_x,
int  origin_y 
)
Function Description
This function writes the postscript command of the net object o_current into the FILE fp points to.
Parameters:
[in]toplevelThe TOPLEVEL object
[in]fppointer to a FILE structure
[in]o_currentThe OBJECT to print
[in]origin_xx-coord of the postscript origin
[in]origin_yy-coord of the postscript origin

Definition at line 263 of file o_net_basic.c.

Here is the call graph for this function:

void world_get_net_bounds ( TOPLEVEL toplevel,
OBJECT object,
int *  left,
int *  top,
int *  right,
int *  bottom 
)
Function Description
This function calculates the object boudaries of a net object.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]objecta net object
[out]leftthe left world coord
[out]topthe top world coord
[out]rightthe right world coord
[out]bottomthe bottom world coord

Definition at line 62 of file o_net_basic.c.

Here is the call graph for this function:

gboolean o_net_get_position ( TOPLEVEL toplevel,
gint *  x,
gint *  y,
OBJECT object 
)
Function Description
This function gets the position of the first point of a net object.
Parameters:
[in]toplevelThe toplevel environment.
[out]xpointer to the x-position
[out]ypointer to the y-position
[in]objectThe object to get the position.
Returns:
TRUE if successfully determined the position, FALSE otherwise

Definition at line 45 of file o_net_basic.c.

Here is the call graph for this function:

void o_net_recalc ( TOPLEVEL toplevel,
OBJECT o_current 
)
Function Description
This function updates the visual coords of the o_current object.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]o_currenta net object.

Definition at line 111 of file o_net_basic.c.

Here is the call graph for this function:

OBJECT* o_path_read ( TOPLEVEL toplevel,
const char *  first_line,
TextBuffer tb,
unsigned int  release_ver,
unsigned int  fileformat_ver,
GError **  err 
)
Function Description
This function creates a path OBJECT from the character string *buf and a number of lines following that describing the path, read from *tb.

Depending on *version, the correct file format is considered. Currently two file format revisions are supported :

*
the file format used until 20010704 release.
*
the file format used for the releases after 20010704.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]first_lineCharacter string with path description.
[in]tbText buffer containing the path string.
[in]release_verlibgeda release version number.
[in]fileformat_verlibgeda file format version number.
Returns:
A pointer to the new path object, or NULL on error;

Definition at line 155 of file o_path_basic.c.

Here is the call graph for this function:

char* o_path_save ( TOPLEVEL toplevel,
OBJECT object 
)
Function Description
The function formats a string in the buffer *buff to describe the path object *object.
Parameters:
[in]toplevela TOPLEVEL structure
[in]objectpath OBJECT to create string from.
Returns:
A pointer to the path OBJECT character string.
Note:
Caller must g_free returned character string.

Definition at line 246 of file o_path_basic.c.

Here is the call graph for this function:

void o_path_print ( TOPLEVEL toplevel,
FILE *  fp,
OBJECT o_current,
int  origin_x,
int  origin_y 
)
Function Description
This function prints the path described by the o_current parameter to a Postscript document. The Postscript document is descibed by the file pointer fp.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]o_currentPATH OBJECT to write to document.
[in]origin_xPage x coordinate to place PATH OBJECT.
[in]origin_yPage y coordinate to place PATH OBJECT.

Note:
Depending on the type of the line for this particular path, the appropriate function is chosen among o_path_print_solid(), o_path_print_dotted(), o_path_print_dashed(), o_path_print_center() and o_path_print_phantom().

The needed parameters for each of these type is extracted from the o_current object. Depending on the type, unused parameters are set to -1.

In the eventuality of a length and/or space null, the line is printed solid to avoid and endless loop produced by other functions in such a case.

Note:
If the filling type of the path is not HOLLOW, the appropriate function is chosen among o_path_print_filled(), o_path_print_mesh() and o_path_print_hatch(). The corresponding parameters are extracted from the o_current object and corrected afterward.

The case where pitch1 and pitch2 are null or negative is avoided as it leads to an endless loop in most of the called functions. In such a case, the path is printed filled. Unused parameters for each of these functions are set to -1 or any passive value.

Definition at line 907 of file o_path_basic.c.

Here is the call graph for this function:

double o_path_shortest_distance ( OBJECT object,
int  x,
int  y,
int  force_solid 
)
Parameters:
[in]objectThe path OBJECT.
[in]xThe x coordinate of the given point.
[in]yThe y coordinate of the given point.
[in]force_solidIf true, force treating the object as solid.
Returns:
The shortest distance from the object to the point. With an invalid parameter, this function returns G_MAXDOUBLE.

Definition at line 1055 of file o_path_basic.c.

Here is the call graph for this function:

void world_get_path_bounds ( TOPLEVEL toplevel,
OBJECT object,
int *  left,
int *  top,
int *  right,
int *  bottom 
)
Function Description
This function sets the left, top, right and bottom parameters to the boundings of the path object described in *path in world units.
Note:
Bounding box for bezier curves is loose because we just consider the convex hull of the curve control and end-points.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]objectLine OBJECT to read coordinates from.
[out]leftLeft path coordinate in WORLD units.
[out]topTop path coordinate in WORLD units.
[out]rightRight path coordinate in WORLD units.
[out]bottomBottom path coordinate in WORLD units.

Definition at line 518 of file o_path_basic.c.

gboolean o_path_get_position ( TOPLEVEL toplevel,
gint *  x,
gint *  y,
OBJECT object 
)
Function Description
This function gets the position of the first point of an path object.
Parameters:
[in]toplevelThe toplevel environment.
[out]xpointer to the x-position
[out]ypointer to the y-position
[in]objectThe object to get the position.
Returns:
TRUE if successfully determined the position, FALSE otherwise

Definition at line 577 of file o_path_basic.c.

void o_path_recalc ( TOPLEVEL toplevel,
OBJECT o_current 
)
Function Description
This function recalculate the bounding box of the o_current
Parameters:
[in]toplevelThe TOPLEVEL object.
[in,out]o_currentLine OBJECT to be recalculated.

Definition at line 482 of file o_path_basic.c.

Here is the call graph for this function:

OBJECT* o_picture_read ( TOPLEVEL toplevel,
const char *  first_line,
TextBuffer tb,
unsigned int  release_ver,
unsigned int  fileformat_ver,
GError **  err 
)
Function Description
Parses first_line and subsequent lines from tb, and returns a newly-created picture OBJECT.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]first_lineCharacter string with picture description.
[in]tbText buffer to load embedded data from.
[in]release_verlibgeda release version number.
[in]fileformat_verlibgeda file format version number.
Returns:
A pointer to the new picture object, or NULL on error.

Definition at line 50 of file o_picture.c.

Here is the call graph for this function:

char* o_picture_save ( TOPLEVEL toplevel,
OBJECT object 
)
Function Description
This function formats a string in the buffer *buff to describe the picture object *object.
Parameters:
[in]toplevela TOPLEVEL structure
[in]objectPicture OBJECT to create string from.
Returns:
A pointer to the picture OBJECT character string.
Note:
Caller must g_free returned character string.

Definition at line 180 of file o_picture.c.

Here is the call graph for this function:

void o_picture_print ( TOPLEVEL toplevel,
FILE *  fp,
OBJECT o_current,
int  origin_x,
int  origin_y 
)
Function Description
This function prints a picture object. The picture is defined by the coordinates of its upper left corner in (x,y) and its width and height given by the width and height parameters.

If the picture object was unable to be loaded, prints a crossed box of the same dimensions.

The Postscript document is defined by the file pointer fp. Function based on the DIA source code (http://www.gnome.org/projects/dia) and licensed under the GNU GPL version 2.

All dimensions are in mils.

Parameters:
[in]toplevelThe TOPLEVEL object.
[in]fpFILE pointer to Postscript document.
[in]o_currentPicture OBJECT to write to document.
[in]origin_xPage x coordinate to place picture OBJECT.
[in]origin_yPage y coordinate to place picture OBJECT.

Definition at line 856 of file o_picture.c.

Here is the call graph for this function:

double o_picture_shortest_distance ( OBJECT object,
int  x,
int  y,
int  force_solid 
)

Interrior points within the picture return a distance of zero.

Parameters:
[in]objectThe picture OBJECT.
[in]xThe x coordinate of the given point.
[in]yThe y coordinate of the given point.
[in]force_solidIf true, force treating the object as solid.
Returns:
The shortest distance from the object to the point. With an invalid parameter, this function returns G_MAXDOUBLE.

Definition at line 1016 of file o_picture.c.

void world_get_picture_bounds ( TOPLEVEL toplevel,
OBJECT object,
int *  left,
int *  top,
int *  right,
int *  bottom 
)
Function Description
This function sets the left, top, right and bottom parameters to the boundings of the picture object described in *picture in WORLD units.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]objectPicture OBJECT to read coordinates from.
[out]leftLeft picture coordinate in WORLD units.
[out]topTop picture coordinate in WORLD units.
[out]rightRight picture coordinate in WORLD units.
[out]bottomBottom picture coordinate in WORLD units.

Definition at line 372 of file o_picture.c.

gboolean o_picture_get_position ( TOPLEVEL toplevel,
gint *  x,
gint *  y,
OBJECT object 
)
Function Description
This function gets the position of the bottom left point of a picture object.
Parameters:
[in]toplevelThe toplevel environment.
[out]xpointer to the x-position
[out]ypointer to the y-position
[in]objectThe object to get the position.
Returns:
TRUE if successfully determined the position, FALSE otherwise

Definition at line 392 of file o_picture.c.

void o_picture_recalc ( TOPLEVEL toplevel,
OBJECT o_current 
)
Function Description
This function recalculates the bounding box of the o_current parameter picture object.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in,out]o_currentPicture OBJECT to be recalculated.

Definition at line 341 of file o_picture.c.

Here is the call graph for this function:

void o_picture_embed ( TOPLEVEL toplevel,
OBJECT object 
)
Function Description
Verify that a picture has valid data associated with it, and if so, mark it to be embedded.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]objectThe picture OBJECT to embed

Definition at line 949 of file o_picture.c.

Here is the call graph for this function:

void o_picture_unembed ( TOPLEVEL toplevel,
OBJECT object 
)
Function Description
Verify that the file associated with object exists on disk and is usable, and if so, reload the picture and mark it as unembedded.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]objectThe picture OBJECT to unembed

Definition at line 979 of file o_picture.c.

Here is the call graph for this function:

OBJECT* o_pin_read ( TOPLEVEL toplevel,
const char  buf[],
unsigned int  release_ver,
unsigned int  fileformat_ver,
GError **  err 
)
Function Description
This function reads a pin object from the buffer buf. If the pin object was read successfully, a new pin object is allocated and appended to the object_list.
Parameters:
[in]toplevelThe TOPLEVEL object
[in]bufa text buffer (usually a line of a schematic file)
[in]release_verThe release number gEDA
[in]fileformat_vera integer value of the file format
Returns:
The object list, or NULL on error.

Definition at line 147 of file o_pin_basic.c.

Here is the call graph for this function:

char* o_pin_save ( TOPLEVEL toplevel,
OBJECT object 
)
Function Description
This function takes a pin object and return a string according to the file format definition.
Parameters:
[in]toplevela TOPLEVEL structure
[in]objecta pin OBJECT
Returns:
the string representation of the pin OBJECT

Definition at line 207 of file o_pin_basic.c.

void o_pin_print ( TOPLEVEL toplevel,
FILE *  fp,
OBJECT o_current,
int  origin_x,
int  origin_y 
)
Function Description
This function writes the postscript command of the pin object o_current into the FILE fp points to.
Parameters:
[in]toplevelThe TOPLEVEL object
[in]fppointer to a FILE structure
[in]o_currentThe OBJECT to print
[in]origin_xx-coord of the postscript origin
[in]origin_yy-coord of the postscript origin

Definition at line 280 of file o_pin_basic.c.

Here is the call graph for this function:

void world_get_pin_bounds ( TOPLEVEL toplevel,
OBJECT object,
int *  left,
int *  top,
int *  right,
int *  bottom 
)
Function Description
This function calculates the object boudaries of a pin object.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]objecta pin object
[out]leftthe left world coord
[out]topthe top world coord
[out]rightthe right world coord
[out]bottomthe bottom world coord

Definition at line 46 of file o_pin_basic.c.

Here is the call graph for this function:

gboolean o_pin_get_position ( TOPLEVEL toplevel,
gint *  x,
gint *  y,
OBJECT object 
)
Function Description
This function gets the position of the whichend side of a pin object.
Parameters:
[in]toplevelThe toplevel environment.
[out]xpointer to the x-position
[out]ypointer to the y-position
[in]objectThe object to get the position.
Returns:
TRUE if successfully determined the position, FALSE otherwise

Definition at line 62 of file o_pin_basic.c.

void o_pin_recalc ( TOPLEVEL toplevel,
OBJECT o_current 
)
Function Description
This function updates the visual coords of the o_current object.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]o_currenta pin object.

Definition at line 118 of file o_pin_basic.c.

Here is the call graph for this function:

OBJECT* o_text_read ( TOPLEVEL toplevel,
const char *  first_line,
TextBuffer tb,
unsigned int  release_ver,
unsigned int  fileformat_ver,
GError **  err 
)
Function Description
This function reads a text object from the textbuffer tb and the text starting with the line firstline. If the line object was read successfully, a new object is create and appended to the object_list.
Parameters:
[in]toplevelThe TOPLEVEL object
[in]first_linethe first line of the text
[in]tba text buffer (usually a line of a schematic file)
[in]release_verThe release number gEDA
[in]fileformat_vera integer value of the file format
Returns:
The object list, or NULL on error.

Definition at line 330 of file o_text_basic.c.

Here is the call graph for this function:

char* o_text_save ( TOPLEVEL toplevel,
OBJECT object 
)
Function Description
This function takes a text object and return a string according to the file format definition.
Parameters:
[in]toplevela TOPLEVEL structure
[in]objecta text OBJECT
Returns:
the string representation of the text OBJECT

Definition at line 485 of file o_text_basic.c.

Here is the call graph for this function:

void o_text_print_text_string ( FILE *  fp,
char *  string,
int  unicode_count,
gunichar *  unicode_table 
)
Function Description
This function writes the single string into the postscript file fp.
Parameters:
[in]fppointer to a FILE structure
[in]stringThe string to print
[in]unicode_countNumber of items in the unicode table
[in]unicode_tableTable of unicode items
Todo:
investigate whether the TAB character is handled correctly

Definition at line 582 of file o_text_basic.c.

void o_text_print ( TOPLEVEL toplevel,
FILE *  fp,
OBJECT o_current,
int  origin_x,
int  origin_y,
int  unicode_count,
gunichar *  unicode_table 
)
Function Description
This function writes the postscript representation of the text object o_current into the the file fp.
Parameters:
[in]toplevelThe TOPLEVEL object
[in]fppointer to a FILE structure
[in]o_currentThe OBJECT to print
[in]origin_xx-coord of the postscript origin
[in]origin_yy-coord of the postscript origin
[in]unicode_countNumber of items in the unicode table
[in]unicode_tableTable of unicode items

Definition at line 643 of file o_text_basic.c.

Here is the call graph for this function:

double o_text_shortest_distance ( OBJECT object,
int  x,
int  y,
int  force_solid 
)

This function will calculate the distance to the text regardless if the text is visible or not.

Parameters:
[in]objectThe text OBJECT.
[in]xThe x coordinate of the given point.
[in]yThe y coordinate of the given point.
[in]force_solidIf true, force treating the object as solid.
Returns:
The shortest distance from the object to the point. If the distance cannot be calculated, this function returns a really large number (G_MAXDOUBLE). With an invalid parameter, this funciton returns G_MAXDOUBLE.

Definition at line 938 of file o_text_basic.c.

int world_get_text_bounds ( TOPLEVEL toplevel,
OBJECT o_current,
int *  left,
int *  top,
int *  right,
int *  bottom 
)
Function Description
This function calculates the object boudaries of a text object.
Parameters:
[in]toplevelThe TOPLEVEL object.
[in]o_currenta text object
[out]leftthe left world coord
[out]topthe top world coord
[out]rightthe right world coord
[out]bottomthe bottom world coord

Definition at line 166 of file o_text_basic.c.

gboolean o_text_get_position ( TOPLEVEL toplevel,
gint *  x,
gint *  y,
OBJECT object 
)
Function Description
This function gets the position of the base point of a text object.
Parameters:
[in]toplevelThe toplevel environment.
[out]xpointer to the x-position
[out]ypointer to the y-position
[in]objectThe object to get the position.
Returns:
TRUE if successfully determined the position, FALSE otherwise

Definition at line 189 of file o_text_basic.c.

void o_text_recalc ( TOPLEVEL toplevel,
OBJECT o_current 
)
Function Description
This function updates the boundaries of the object o_current.
Parameters:
[in]toplevelThe TOPLEVEL object
[in]o_currentThe OBJECT to update

Definition at line 297 of file o_text_basic.c.

Here is the call graph for this function:

void s_clib_init ( void  )
Function Description
Resets and initialises the component library.
Warning:
This function must be called before any other functions from s_clib.c.

Definition at line 260 of file s_clib.c.

Here is the call graph for this function:

void s_color_init ( void  )
Function Description
At the moment, just initialises the print color map.

Definition at line 76 of file s_color.c.

Here is the call graph for this function:

gchar* s_color_ps_string ( gint  color)
Todo:
Finish function documentation!!!
Function Description

Definition at line 202 of file s_color.c.

CONN* s_conn_return_new ( OBJECT other_object,
int  type,
int  x,
int  y,
int  whichone,
int  other_whichone 
)
Function Description
create a single st_conn object and initialize it with the given parameters.
Returns:
The new connection object

Definition at line 59 of file s_conn.c.

int s_conn_uniq ( GList *  conn_list,
CONN input_conn 
)
Function Description
This function checks if there's no identical connection in the list of connections.
Parameters:
conn_listlist of connection objects
input_connsingle connection object.
Returns:
TRUE if the CONN structure is unique, FALSE otherwise.

Definition at line 88 of file s_conn.c.

int s_conn_remove_other ( TOPLEVEL toplevel,
OBJECT other_object,
OBJECT to_remove 
)
Function Description
This function removes the OBJECT to_remove from the connection list of the OBJECT other_object.
Parameters:
toplevel(currently not used)
other_objectOBJECT from that the to_remove OBJECT needs to be removed
to_removeOBJECT to remove
Returns:
TRUE if a connection has been deleted, FALSE otherwise

Definition at line 118 of file s_conn.c.

Here is the call graph for this function:

OBJECT* s_conn_check_midpoint ( OBJECT o_current,
int  x,
int  y 
)
Function Description
Checks if the point (x,y) is on the OBJECT and between it's endpoints.
Returns:
TRUE if the point is a midpoint of the OBJECT. FALSE if the point is not a midpoinit or if the OBJECT is not a NET a PIN or a BUS or if the OBJECT has neither horizontal nor vertical orientation.

Definition at line 240 of file s_conn.c.

void s_conn_print ( GList *  conn_list)
Function Description
This is a debugging function to print a List of connections.
Parameters:
conn_listGList of connection objects

Definition at line 526 of file s_conn.c.

void s_conn_init ( void  )

Definition at line 742 of file s_conn.c.

Here is the call graph for this function:

gchar* s_encoding_base64_encode ( gchar *  src,
guint  srclen,
guint *  dstlenp,
gboolean  strict 
)
Function Description
Convert a buffer from binary to base64 representation. Set strict to TRUE to insert a newline every 72th character. This is required by RFC 2045, but some applications don't require this.
Parameters:
[in]srcSource buffer.
[in]srclenLength of source buffer.
[out]dstlenpLength of buffer returned (including the terminating \0).
[in]strictInsert new lines as required by RFC 2045.
Returns:
Caller owned buffer containing base64 representation.

Definition at line 82 of file s_encoding.c.

gchar* s_encoding_base64_decode ( gchar *  src,
guint  srclen,
guint *  dstlenp 
)
Function Description
Convert a buffer from base64 to binary representation. This function is liberal in what it will accept. It ignores non-base64 symbols.
Parameters:
[in]srcSource buffer.
[in]srclenLength of the source buffer.
[out]dstlenpPointer to length of the destination buffer
Returns:
Caller-owned buffer with binary representation. The integer pointed to by dstlenp is set to the length of that buffer.

Definition at line 191 of file s_encoding.c.

int s_path_to_polygon ( PATH path,
GArray *  points 
)
Parameters:
path[in] The path to convert to a polygon. This parameter must not be NULL.
points[out] An array of the polygon's vertices. This parameter must not be NULL.
Returns:
TRUE if the path is closed, FALSE if it is open.

Definition at line 708 of file s_path.c.

Here is the call graph for this function:

double s_path_shortest_distance ( PATH path,
int  x,
int  y,
int  solid 
)
Parameters:
[in]pathThe path.
[in]xThe x coordinate of the given point.
[in]yThe y coordinate of the given point.
[in]solidTRUE if the path should be treated as solid, FALSE if the path should be treated as hollow.
Returns:
The shortest distance from the path to the point. With a solid shape, this function returns a distance of zero for interior points. With an invalid parameter, this function returns G_MAXDOUBLE.

Definition at line 768 of file s_path.c.

Here is the call graph for this function:

TextBuffer* s_textbuffer_new ( const gchar *  data,
const gint  size 
)
Function description
Allocates and initialises a new TextBuffer to manage the given data buffer.

If the size argument is negative, assumes that data is null-terminated.

Parameters:
dataThe address of the buffer to be managed.
sizeThe length of the buffer.
Return values:
Pointerto a new TextBuffer struct.

Definition at line 62 of file s_textbuffer.c.

TextBuffer* s_textbuffer_free ( TextBuffer tb)
Function description
Cleans up all of the resources associated with a given TextBuffer.

Should be called thus:

  tb = s_textbuffer_free (tb);

Definition at line 97 of file s_textbuffer.c.

const gchar* s_textbuffer_next ( TextBuffer tb,
const gssize  count 
)
Function description
Get some number of characters from a TextBuffer, starting at the current position. If the end of the buffer has been reached (and thus no more characters remain) returns null. If count is -1, obtains all characters up to and including the next newline.

A newline is detected as '
', or '' together with its immediately following '
', or '', in that order. All newlines are collapsed into a single '
'.

The returned character array should be considered highly volatile, and is only valid until the next call to s_textbuffer_next() or s_textbuffer_next_line().

Parameters:
tbTextBuffer to read from.
countMaximum number of characters to read.
Return values:
Characterarray, or NULL if no characters left.

Definition at line 128 of file s_textbuffer.c.

const gchar* s_textbuffer_next_line ( TextBuffer tb)
Function description
Get the next line of characters from a TextBuffer, starting from the current position. If the end of the buffer has been reached (and thus no more characters remain) returns null.

The returned character array should be considered highly volatile, and is only valid until the next call to s_textbuffer_next() or s_textbuffer_next_line().

Parameters:
tbTextBuffer to read from.
Return values:
Characterarray, or NULL if no characters left.

Definition at line 193 of file s_textbuffer.c.

Here is the call graph for this function:

void s_tile_init ( TOPLEVEL toplevel,
PAGE p_current 
)
Function Description
This function splits the page size into tiles and initializes every tile.
Parameters:
toplevelTOPLEVEL structure
p_currentThe page that gets the tiles.

Definition at line 58 of file s_tile.c.

void s_tile_add_object ( TOPLEVEL toplevel,
OBJECT object 
)
Function Description
This function takes dispatches the object to the correct function, depending on its type.
Parameters:
toplevelThe TOPLEVEL structure
objectThe line OBJECT to add

Definition at line 308 of file s_tile.c.

Here is the call graph for this function:

void s_tile_remove_object ( OBJECT object)
Function Description
This function remose an object from all tiles that are refered by the object. It also removes the object from each tile that contained the object.
Parameters:
objectThe object to remove

Definition at line 335 of file s_tile.c.

Here is the call graph for this function:

void s_tile_print ( TOPLEVEL toplevel,
PAGE page 
)
Function Description
Debugging function to print all object names that are inside the tiles.

Definition at line 432 of file s_tile.c.

void s_tile_free_all ( PAGE p_current)
Function Description
This function removes all objects from the tiles of the given page.
Parameters:
[in]p_currentThe PAGE to clean up the tiles
Note:
In theory, calling this function is not required. If all objects have been removed from a page, all object lists of the tiles should be empty.

Definition at line 468 of file s_tile.c.

void s_weakref_notify ( void *  dead_ptr,
GList *  weak_refs 
)
Function Description
For each entry in weak_refs, call notify function with the dead pointer dead_ptr and the entry's specified user data, and free weak_refs. Should be called during destruction of an structure that allows weak references.
Parameters:
[in]dead_ptrPointer to structure being destroyed.
[in,out]weak_refsList of registered weak references.

Definition at line 48 of file s_weakref.c.

GList* s_weakref_add ( GList *  weak_refs,
void(*)(void *, void *)  notify_func,
void *  user_data 
)
Function Description
Adds the weak reference callback notify_func to the weak reference list weak_refs, returning the new head of weak_refs. notify_func will be called with two arguments: a pointer to the object being destroyed, and the user_data.
Parameters:
[in,out]weak_refsList of registered weak references.
[in]notify_funcWeak reference notify function.
[in]user_dataData to be passed to notify_func.
Returns:
new head of weak_refs list.

Definition at line 76 of file s_weakref.c.

GList* s_weakref_remove ( GList *  weak_refs,
void(*)(void *, void *)  notify_func,
void *  user_data 
)
Function Description
Removes a weak reference callback from the weak reference list weak_refs, returning the new head of weak_refs.
Parameters:
[in,out]weak_refsList of registered weak references.
[in]notify_funcNotify function to search for.
[in]user_dataUser data to search for.
Returns:
new head of weak_refs list.

Definition at line 97 of file s_weakref.c.

GList* s_weakref_add_ptr ( GList *  weak_refs,
void **  weak_pointer_loc 
)
Function Description
Adds a weak reference for weak_pointer_loc to the weak reference list weak_refs, returning the new head of weak_refs.
Parameters:
[in,out]weak_refsList of registered weak references.
[in]weak_pointer_locMemory address of a pointer.
Returns:
new head of weak_refs list.

Definition at line 133 of file s_weakref.c.

Here is the call graph for this function:

GList* s_weakref_remove_ptr ( GList *  weak_refs,
void **  weak_pointer_loc 
)
Function Description
Removes the weak reference for weak_pointer_loc from the weak reference list weak_refs, returning the new head of weak_refs.
Parameters:
[in,out]weak_refsList of registered weak references.
[in]weak_pointer_locMemory address of a pointer.
Returns:
new head of weak_refs list.

Definition at line 150 of file s_weakref.c.

Here is the call graph for this function:

 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines