Index: trunk/src/buffer.c =================================================================== --- trunk/src/buffer.c (revision 4757) +++ trunk/src/buffer.c (revision 4758) @@ -81,7 +81,7 @@ /* --------------------------------------------------------------------------- * calculates the bounding box of the buffer */ -void SetBufferBoundingBox(BufferTypePtr Buffer) +void SetBufferBoundingBox(pcb_buffer_t *Buffer) { BoxTypePtr box = GetDataBoundingBox(Buffer->Data); @@ -92,7 +92,7 @@ /* --------------------------------------------------------------------------- * clears the contents of the paste buffer */ -void ClearBuffer(BufferTypePtr Buffer) +void ClearBuffer(pcb_buffer_t *Buffer) { if (Buffer && Buffer->Data) { FreeDataMemory(Buffer->Data); @@ -104,7 +104,7 @@ * copies all selected and visible objects to the paste buffer * returns true if any objects have been removed */ -void AddSelectedToBuffer(BufferTypePtr Buffer, Coord X, Coord Y, pcb_bool LeaveSelected) +void AddSelectedToBuffer(pcb_buffer_t *Buffer, Coord X, Coord Y, pcb_bool LeaveSelected) { pcb_opctx_t ctx; @@ -193,7 +193,7 @@ * parse the file with enabled 'PCB mode' (see parser) * if successful, update some other stuff */ -pcb_bool LoadLayoutToBuffer(BufferTypePtr Buffer, const char *Filename, const char *fmt) +pcb_bool LoadLayoutToBuffer(pcb_buffer_t *Buffer, const char *Filename, const char *fmt) { pcb_board_t *newPCB = CreateNewPCB(); @@ -220,7 +220,7 @@ /* --------------------------------------------------------------------------- * rotates the contents of the pastebuffer */ -void RotateBuffer(BufferTypePtr Buffer, pcb_uint8_t Number) +void RotateBuffer(pcb_buffer_t *Buffer, pcb_uint8_t Number) { /* rotate vias */ VIA_LOOP(Buffer->Data); @@ -274,7 +274,7 @@ RotateBoxLowLevel(&Buffer->BoundingBox, Buffer->X, Buffer->Y, Number); } -void FreeRotateBuffer(BufferTypePtr Buffer, Angle angle) +void FreeRotateBuffer(pcb_buffer_t *Buffer, Angle angle) { double cosa, sina; @@ -397,7 +397,7 @@ } -void MirrorBuffer(BufferTypePtr Buffer) +void MirrorBuffer(pcb_buffer_t *Buffer) { int i; @@ -456,7 +456,7 @@ /* --------------------------------------------------------------------------- * flip components/tracks from one side to the other */ -void SwapBuffer(BufferTypePtr Buffer) +void SwapBuffer(pcb_buffer_t *Buffer) { int j, k; pcb_cardinal_t sgroup, cgroup; Index: trunk/src/buffer.h =================================================================== --- trunk/src/buffer.h (revision 4757) +++ trunk/src/buffer.h (revision 4758) @@ -41,15 +41,15 @@ /* --------------------------------------------------------------------------- * prototypes */ -void SwapBuffer(BufferTypePtr Buffer); -void SetBufferBoundingBox(BufferTypePtr); -void ClearBuffer(BufferTypePtr); -void AddSelectedToBuffer(BufferTypePtr, Coord, Coord, pcb_bool); -pcb_bool LoadLayoutToBuffer(BufferTypePtr Buffer, const char *Filename, const char *fmt); -void RotateBuffer(BufferTypePtr, pcb_uint8_t); +void SwapBuffer(pcb_buffer_t *Buffer); +void SetBufferBoundingBox(pcb_buffer_t *); +void ClearBuffer(pcb_buffer_t *); +void AddSelectedToBuffer(pcb_buffer_t *, Coord, Coord, pcb_bool); +pcb_bool LoadLayoutToBuffer(pcb_buffer_t *Buffer, const char *Filename, const char *fmt); +void RotateBuffer(pcb_buffer_t *, pcb_uint8_t); void SelectPasteBuffer(int); void pcb_swap_buffers(void); -void MirrorBuffer(BufferTypePtr); +void MirrorBuffer(pcb_buffer_t *); void InitBuffers(void); void UninitBuffers(void); void *MoveObjectToBuffer(pcb_data_t *, pcb_data_t *, int, void *, void *, void *); Index: trunk/src/crosshair.c =================================================================== --- trunk/src/crosshair.c (revision 4757) +++ trunk/src/crosshair.c (revision 4758) @@ -55,7 +55,7 @@ */ static void XORPolygon(PolygonTypePtr, Coord, Coord, int); static void XORDrawElement(ElementTypePtr, Coord, Coord); -static void XORDrawBuffer(BufferTypePtr); +static void XORDrawBuffer(pcb_buffer_t *); static void XORDrawInsertPointObject(void); static void XORDrawMoveOrCopyObject(void); static void XORDrawAttachedLine(Coord, Coord, Coord, Coord, Coord); @@ -274,7 +274,7 @@ /* --------------------------------------------------------------------------- * draws all visible and attached objects of the pastebuffer */ -static void XORDrawBuffer(BufferTypePtr Buffer) +static void XORDrawBuffer(pcb_buffer_t *Buffer) { pcb_cardinal_t i; Coord x, y; Index: trunk/src/data.c =================================================================== --- trunk/src/data.c (revision 4757) +++ trunk/src/data.c (revision 4758) @@ -43,7 +43,7 @@ int LayerStack[MAX_LAYER]; /* determines the layer draw order */ -BufferType Buffers[MAX_BUFFER]; /* my buffers */ +pcb_buffer_t Buffers[MAX_BUFFER]; /* my buffers */ pcb_bool Bumped; /* if the undo serial number has changed */ int addedLines; Index: trunk/src/data.h =================================================================== --- trunk/src/data.h (revision 4757) +++ trunk/src/data.h (revision 4758) @@ -65,7 +65,7 @@ #define solder_silk_layer (max_copper_layer + SOLDER_LAYER) #define component_silk_layer (max_copper_layer + COMPONENT_LAYER) -extern BufferType Buffers[MAX_BUFFER]; +extern pcb_buffer_t Buffers[MAX_BUFFER]; /*extern DeviceInfoType PrintingDevice[];*/ Index: trunk/src/global_typedefs.h =================================================================== --- trunk/src/global_typedefs.h (revision 4757) +++ trunk/src/global_typedefs.h (revision 4758) @@ -28,7 +28,7 @@ typedef struct pcb_data_s pcb_data_t; typedef struct pcb_layer_group_s pcb_layer_group_t; typedef struct pcb_layer_s pcb_layer_t; -typedef struct pcb_buffer_s BufferType, *BufferTypePtr; +typedef struct pcb_buffer_s pcb_buffer_t; typedef struct pcb_net_s NetType, *NetTypePtr; typedef struct pcb_connection_s ConnectionType, *ConnectionTypePtr; typedef struct pcb_box_s BoxType, *BoxTypePtr; Index: trunk/src/obj_elem.c =================================================================== --- trunk/src/obj_elem.c (revision 4757) +++ trunk/src/obj_elem.c (revision 4758) @@ -122,7 +122,7 @@ * returns pcb_false on error * if successful, update some other stuff and reposition the pastebuffer */ -pcb_bool LoadElementToBuffer(BufferTypePtr Buffer, const char *Name) +pcb_bool LoadElementToBuffer(pcb_buffer_t *Buffer, const char *Name) { ElementTypePtr element; @@ -151,7 +151,7 @@ /* Searches for the given element by "footprint" name, and loads it into the buffer. Returns zero on success, non-zero on error. */ -int LoadFootprintByName(BufferTypePtr Buffer, const char *Footprint) +int LoadFootprintByName(pcb_buffer_t *Buffer, const char *Footprint) { return !LoadElementToBuffer(Buffer, Footprint); } @@ -158,7 +158,7 @@ /* break buffer element into pieces */ -pcb_bool SmashBufferElement(BufferTypePtr Buffer) +pcb_bool SmashBufferElement(pcb_buffer_t *Buffer) { ElementTypePtr element; pcb_cardinal_t group; @@ -253,7 +253,7 @@ } /* convert buffer contents into an element */ -pcb_bool ConvertBufferToElement(BufferTypePtr Buffer) +pcb_bool ConvertBufferToElement(pcb_buffer_t *Buffer) { ElementTypePtr Element; pcb_cardinal_t group; Index: trunk/src/obj_elem.h =================================================================== --- trunk/src/obj_elem.h (revision 4757) +++ trunk/src/obj_elem.h (revision 4758) @@ -55,10 +55,10 @@ LineType *GetElementLineMemory(ElementType *Element); -pcb_bool LoadElementToBuffer(BufferTypePtr Buffer, const char *Name); -int LoadFootprintByName(BufferTypePtr Buffer, const char *Footprint); -pcb_bool SmashBufferElement(BufferTypePtr Buffer); -pcb_bool ConvertBufferToElement(BufferTypePtr Buffer); +pcb_bool LoadElementToBuffer(pcb_buffer_t *Buffer, const char *Name); +int LoadFootprintByName(pcb_buffer_t *Buffer, const char *Footprint); +pcb_bool SmashBufferElement(pcb_buffer_t *Buffer); +pcb_bool ConvertBufferToElement(pcb_buffer_t *Buffer); void FreeRotateElementLowLevel(pcb_data_t *Data, ElementTypePtr Element, Coord X, Coord Y, double cosa, double sina, Angle angle); pcb_bool ChangeElementSide(ElementTypePtr Element, Coord yoff); pcb_bool ChangeSelectedElementSide(void); Index: trunk/src/plug_io.c =================================================================== --- trunk/src/plug_io.c (revision 4757) +++ trunk/src/plug_io.c (revision 4758) @@ -217,7 +217,7 @@ } -int WriteBuffer(FILE *f, BufferType *buff, const char *fmt) +int WriteBuffer(FILE *f, pcb_buffer_t *buff, const char *fmt) { int res, newfmt = 0; plug_io_t *p = find_writer(PCB_IOT_BUFFER, fmt); Index: trunk/src/plug_io.h =================================================================== --- trunk/src/plug_io.h (revision 4757) +++ trunk/src/plug_io.h (revision 4758) @@ -69,7 +69,7 @@ /* Write the buffer to a file. Return 0 on success. */ - int (*write_buffer)(plug_io_t *ctx, FILE *f, BufferType *buff); + int (*write_buffer)(plug_io_t *ctx, FILE *f, pcb_buffer_t *buff); /* Write element data to a file. Return 0 on success. */ int (*write_element)(plug_io_t *ctx, FILE *f, pcb_data_t *e); @@ -94,7 +94,7 @@ int ParsePCB(pcb_board_t *Ptr, const char *Filename, const char *fmt, int load_settings); int ParseElement(pcb_data_t *Ptr, const char *name); int ParseFont(FontTypePtr Ptr, char *Filename); -int WriteBuffer(FILE *f, BufferType *buff, const char *fmt); +int WriteBuffer(FILE *f, pcb_buffer_t *buff, const char *fmt); int WriteElementData(FILE *f, pcb_data_t *e, const char *fmt); /********** common function used to be part of file.[ch] and friends **********/ Index: trunk/src_plugins/export_openscad/scadcomp.c =================================================================== --- trunk/src_plugins/export_openscad/scadcomp.c (revision 4757) +++ trunk/src_plugins/export_openscad/scadcomp.c (revision 4758) @@ -347,7 +347,7 @@ -extern void FreeRotateBuffer(BufferType * Buffer, Angle angle); +extern void FreeRotateBuffer(pcb_buffer_t * Buffer, Angle angle); static int scad_calculate_bbox(ElementType * element, Angle angle, float *w, float *h, float *ox, float *oy) { @@ -356,7 +356,7 @@ /* TODO: automatic calculation of bounding box - BufferType element_buffer; + pcb_buffer_t element_buffer; element_buffer.Data = CreateNewBuffer (); Index: trunk/src_plugins/io_kicad/write.c =================================================================== --- trunk/src_plugins/io_kicad/write.c (revision 4757) +++ trunk/src_plugins/io_kicad/write.c (revision 4758) @@ -55,7 +55,7 @@ static int write_kicad_layout_via_drill_size(FILE * FP, pcb_cardinal_t indentation); /* writes the buffer to file */ -int io_kicad_write_buffer(plug_io_t *ctx, FILE * FP, BufferType *buff) +int io_kicad_write_buffer(plug_io_t *ctx, FILE * FP, pcb_buffer_t *buff) { /*fputs("io_kicad_legacy_write_buffer()", FP); */ Index: trunk/src_plugins/io_kicad/write.h =================================================================== --- trunk/src_plugins/io_kicad/write.h (revision 4757) +++ trunk/src_plugins/io_kicad/write.h (revision 4758) @@ -30,7 +30,7 @@ #include "data.h" int io_kicad_write_element(plug_io_t *ctx, FILE * FP, pcb_data_t *Data); -int io_kicad_write_buffer(plug_io_t *ctx, FILE * FP, BufferType *buff); +int io_kicad_write_buffer(plug_io_t *ctx, FILE * FP, pcb_buffer_t *buff); int io_kicad_write_pcb(plug_io_t *ctx, FILE * FP, const char *old_filename, const char *new_filename, pcb_bool emergency); int write_kicad_module_header(FILE * FP, pcb_cardinal_t indentation); int write_kicad_layout_header(FILE * FP, pcb_cardinal_t indentation); Index: trunk/src_plugins/io_kicad_legacy/write.c =================================================================== --- trunk/src_plugins/io_kicad_legacy/write.c (revision 4757) +++ trunk/src_plugins/io_kicad_legacy/write.c (revision 4758) @@ -52,7 +52,7 @@ static int write_kicad_legacy_layout_via_drill_size(FILE * FP); /* writes the buffer to file */ -int io_kicad_legacy_write_buffer(plug_io_t *ctx, FILE * FP, BufferType *buff) +int io_kicad_legacy_write_buffer(plug_io_t *ctx, FILE * FP, pcb_buffer_t *buff) { /*fputs("io_kicad_legacy_write_buffer()", FP); */ Index: trunk/src_plugins/io_kicad_legacy/write.h =================================================================== --- trunk/src_plugins/io_kicad_legacy/write.h (revision 4757) +++ trunk/src_plugins/io_kicad_legacy/write.h (revision 4758) @@ -30,7 +30,7 @@ #include "data.h" int io_kicad_legacy_write_element(plug_io_t *ctx, FILE * FP, pcb_data_t *Data); -int io_kicad_legacy_write_buffer(plug_io_t *ctx, FILE * FP, BufferType *buff); +int io_kicad_legacy_write_buffer(plug_io_t *ctx, FILE * FP, pcb_buffer_t *buff); int io_kicad_legacy_write_pcb(plug_io_t *ctx, FILE * FP, const char *old_filename, const char *new_filename, pcb_bool emergency); int write_kicad_legacy_module_header(FILE * FP); int write_kicad_legacy_layout_header(FILE * FP); Index: trunk/src_plugins/io_pcb/file.c =================================================================== --- trunk/src_plugins/io_pcb/file.c (revision 4757) +++ trunk/src_plugins/io_pcb/file.c (revision 4758) @@ -499,7 +499,7 @@ /* --------------------------------------------------------------------------- * writes the buffer to file */ -int io_pcb_WriteBuffer(plug_io_t *ctx, FILE * FP, BufferType *buff) +int io_pcb_WriteBuffer(plug_io_t *ctx, FILE * FP, pcb_buffer_t *buff) { pcb_cardinal_t i; Index: trunk/src_plugins/io_pcb/file.h =================================================================== --- trunk/src_plugins/io_pcb/file.h (revision 4757) +++ trunk/src_plugins/io_pcb/file.h (revision 4758) @@ -47,7 +47,7 @@ const char *write_coord_fmt; } io_pcb_ctx_t; -int io_pcb_WriteBuffer(plug_io_t *ctx, FILE *f, BufferType *buff); +int io_pcb_WriteBuffer(plug_io_t *ctx, FILE *f, pcb_buffer_t *buff); int io_pcb_WriteElementData(plug_io_t *ctx, FILE *f, pcb_data_t *); int io_pcb_WritePCB(plug_io_t *ctx, FILE *f, const char *old_filename, const char *new_filename, pcb_bool emergency);