libgeda
|
functions for the pin object More...
#include <config.h>
#include <stdio.h>
#include <math.h>
#include "libgeda_priv.h"
Go to the source code of this file.
Functions | |
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 | |
OBJECT * | o_pin_new (TOPLEVEL *toplevel, char type, int color, int x1, int y1, int x2, int y2, int pin_type, int whichend) |
create a new pin object | |
void | o_pin_recalc (TOPLEVEL *toplevel, OBJECT *o_current) |
recalc the visual properties of a pin object | |
OBJECT * | o_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_translate_world (TOPLEVEL *toplevel, int dx, int dy, OBJECT *object) |
move a pin object | |
OBJECT * | o_pin_copy (TOPLEVEL *toplevel, OBJECT *o_current) |
create a copy of a 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 | o_pin_rotate_world (TOPLEVEL *toplevel, int world_centerx, int world_centery, int angle, OBJECT *object) |
rotate a pin object around a centerpoint | |
void | o_pin_mirror_world (TOPLEVEL *toplevel, int world_centerx, int world_centery, OBJECT *object) |
mirror a pin object horizontaly at a centerpoint | |
void | o_pin_modify (TOPLEVEL *toplevel, OBJECT *object, int x, int y, int whichone) |
modify one point of a pin object | |
void | o_pin_update_whichend (TOPLEVEL *toplevel, GList *object_list, int num_pins) |
guess the whichend of pins of object list | |
void | o_pin_set_type (TOPLEVEL *toplevel, OBJECT *o_current, int pin_type) |
Sets the type, and corresponding width of a pin. |
Definition in file o_pin_basic.c.
void world_get_pin_bounds | ( | TOPLEVEL * | toplevel, |
OBJECT * | object, | ||
int * | left, | ||
int * | top, | ||
int * | right, | ||
int * | bottom | ||
) |
[in] | toplevel | The TOPLEVEL object. |
[in] | object | a pin object |
[out] | left | the left world coord |
[out] | top | the top world coord |
[out] | right | the right world coord |
[out] | bottom | the bottom world coord |
Definition at line 46 of file o_pin_basic.c.
[in] | toplevel | The toplevel environment. |
[out] | x | pointer to the x-position |
[out] | y | pointer to the y-position |
[in] | object | The object to get the position. |
Definition at line 62 of file o_pin_basic.c.
OBJECT* o_pin_new | ( | TOPLEVEL * | toplevel, |
char | type, | ||
int | color, | ||
int | x1, | ||
int | y1, | ||
int | x2, | ||
int | y2, | ||
int | pin_type, | ||
int | whichend | ||
) |
[in] | toplevel | The TOPLEVEL object. |
[in] | type | The OBJECT type (usually OBJ_PIN) |
[in] | color | The color of the pin |
[in] | x1 | x-coord of the first point |
[in] | y1 | y-coord of the first point |
[in] | x2 | x-coord of the second point |
[in] | y2 | y-coord of the second point |
[in] | pin_type | type of pin (PIN_TYPE_NET or PIN_TYPE_BUS) |
[in] | whichend | The connectable end of the pin |
Definition at line 85 of file o_pin_basic.c.
[in] | toplevel | The TOPLEVEL object. |
[in] | o_current | a pin object. |
Definition at line 118 of file o_pin_basic.c.
OBJECT* o_pin_read | ( | TOPLEVEL * | toplevel, |
const char | buf[], | ||
unsigned int | release_ver, | ||
unsigned int | fileformat_ver, | ||
GError ** | err | ||
) |
[in] | toplevel | The TOPLEVEL object |
[in] | buf | a text buffer (usually a line of a schematic file) |
[in] | release_ver | The release number gEDA |
[in] | fileformat_ver | a integer value of the file format |
Definition at line 147 of file o_pin_basic.c.
[in] | toplevel | a TOPLEVEL structure |
[in] | object | a pin OBJECT |
Definition at line 207 of file o_pin_basic.c.
[in] | toplevel | The TOPLEVEL object |
[in] | dx | The x-distance to move the object |
[in] | dy | The y-distance to move the object |
[in] | object | The pin OBJECT to be moved |
Definition at line 235 of file o_pin_basic.c.
[in] | toplevel | The TOPLEVEL object |
[in] | o_current | The object that is copied |
Definition at line 257 of file o_pin_basic.c.
[in] | toplevel | The TOPLEVEL object |
[in] | fp | pointer to a FILE structure |
[in] | o_current | The OBJECT to print |
[in] | origin_x | x-coord of the postscript origin |
[in] | origin_y | y-coord of the postscript origin |
Definition at line 280 of file o_pin_basic.c.
void o_pin_rotate_world | ( | TOPLEVEL * | toplevel, |
int | world_centerx, | ||
int | world_centery, | ||
int | angle, | ||
OBJECT * | object | ||
) |
[in] | toplevel | The TOPLEVEL object |
[in] | world_centerx | x-coord of the rotation center |
[in] | world_centery | y-coord of the rotation center |
[in] | angle | The angle to rotat the pin object |
[in] | object | The pin object |
Definition at line 319 of file o_pin_basic.c.
void o_pin_mirror_world | ( | TOPLEVEL * | toplevel, |
int | world_centerx, | ||
int | world_centery, | ||
OBJECT * | object | ||
) |
[in] | toplevel | The TOPLEVEL object |
[in] | world_centerx | x-coord of the mirror position |
[in] | world_centery | y-coord of the mirror position |
[in] | object | The pin object |
Definition at line 356 of file o_pin_basic.c.
toplevel | The TOPLEVEL object |
object | The pin OBJECT to modify |
x | new x-coord of the pin point |
y | new y-coord of the pin point |
whichone | pin point to modify |
Definition at line 382 of file o_pin_basic.c.
void o_pin_update_whichend | ( | TOPLEVEL * | toplevel, |
GList * | object_list, | ||
int | num_pins | ||
) |
toplevel | The TOPLEVEL object |
object_list | list of OBJECTs |
num_pins | pin count in the object list |
Definition at line 407 of file o_pin_basic.c.
[in] | toplevel | The TOPLEVEL object |
[in] | o_current | The pin OBJECT being modified |
[in] | pin_type | The new type of this pin |
Definition at line 560 of file o_pin_basic.c.