pcb 4.1.1
An interactive printed circuit board layout editor.

draw.c File Reference

Drawing routines. More...

#include "global.h"
#include "hid_draw.h"
#include "compat.h"
#include "crosshair.h"
#include "data.h"
#include "draw.h"
#include "error.h"
#include "mymem.h"
#include "misc.h"
#include "rotate.h"
#include "rtree.h"
#include "search.h"
#include "select.h"
#include "print.h"
#include <assert.h>
Include dependency graph for draw.c:

Go to the source code of this file.

Data Structures

struct  hole_info
struct  poly_info

Defines

#define MAXINT   (((unsigned int)(~0))>>1)
#define SMALL_SMALL_TEXT_SIZE   0
#define SMALL_TEXT_SIZE   1
#define NORMAL_TEXT_SIZE   2
#define LARGE_TEXT_SIZE   3
#define N_TEXT_SIZES   4

Functions

static void DrawEverything (const BoxType *drawn_area)
 Initializes some identifiers for a new zoom factor and redraws whole screen.
static void DrawPPV (int group, const BoxType *drawn_area)
 Draws pins pads and vias - Always draws for non-gui HIDs, otherwise drawing depends on PCB->PinOn and PCB->ViaOn.
static void AddPart (void *b)
 Adds the update rect to the update region.
static void DrawEMark (ElementType *, Coord, Coord, bool)
static void DrawRats (const BoxType *)
static void set_object_color (AnyObjectType *obj, char *warn_color, char *selected_color, char *connected_color, char *found_color, char *normal_color)
static void set_layer_object_color (LayerType *layer, AnyObjectType *obj)
void Draw (void)
 Initiate the actual redrawing of the updated area.
void Redraw (void)
 Redraws all the data by the event handlers.
static void _draw_pv_name (PinType *pv)
static void _draw_pv (PinType *pv, bool draw_hole)
static void draw_pin (PinType *pin, bool draw_hole)
static int pin_callback (const BoxType *b, void *cl)
static void draw_via (PinType *via, bool draw_hole)
static bool via_visible_on_layer_group (PinType *via)
static int via_callback (const BoxType *b, void *cl)
static void draw_pad_name (PadType *pad)
static void _draw_pad (hidGC gc, PadType *pad, bool clear, bool mask)
static void draw_pad (PadType *pad)
static int pad_callback (const BoxType *b, void *cl)
static void draw_element_name (ElementType *element)
static int name_callback (const BoxType *b, void *cl)
static void draw_element_pins_and_pads (ElementType *element)
static int EMark_callback (const BoxType *b, void *cl)
static int hole_callback (const BoxType *b, void *cl)
void DrawHoles (bool draw_plated, bool draw_unplated, const BoxType *drawn_area, Cardinal g_from, Cardinal g_to)
static int line_callback (const BoxType *b, void *cl)
static int rat_callback (const BoxType *b, void *cl)
static int arc_callback (const BoxType *b, void *cl)
static void draw_element_package (ElementType *element)
static int element_callback (const BoxType *b, void *cl)
void PrintAssembly (int side, const BoxType *drawn_area)
 Prints assembly drawing.
static int clearPin_callback (const BoxType *b, void *cl)
static int poly_callback (const BoxType *b, void *cl)
static int clearPad_callback (const BoxType *b, void *cl)
void DrawSilk (int side, const BoxType *drawn_area)
 Draws silk layer.
static void DrawMaskBoardArea (int mask_type, const BoxType *drawn_area)
void DrawMask (int side, const BoxType *screen)
 Draws solder mask layer - this will cover nearly everything.
void DrawPaste (int side, const BoxType *drawn_area)
 Draws solder paste layer for a given side of the board.
static int text_callback (const BoxType *b, void *cl)
void DrawLayer (LayerType *Layer, const BoxType *screen)
void DrawLayerGroup (int group, const BoxType *drawn_area)
 Draws one layer group.
static void GatherPVName (PinType *Ptr)
static void GatherPadName (PadType *Pad)
void DrawVia (PinType *Via)
 Draw a via object.
void DrawViaName (PinType *Via)
 Draws the name of a via.
void DrawPin (PinType *Pin)
 Draw a pin object.
void DrawPinName (PinType *Pin)
 Draws the name of a pin.
void DrawPad (PadType *Pad)
 Draw a pad object.
void DrawPadName (PadType *Pad)
 Draws the name of a pad.
void DrawLine (LayerType *Layer, LineType *Line)
 Draws a line on a layer.
void DrawRat (RatType *Rat)
 Draws a ratline.
void DrawArc (LayerType *Layer, ArcType *Arc)
 Draws an arc on a layer.
void DrawText (LayerType *Layer, TextType *Text)
 Draws a text on a layer.
void DrawPolygon (LayerType *Layer, PolygonType *Polygon)
 Draws a polygon on a layer.
void DrawElement (ElementType *Element)
 Draws an element.
void DrawElementName (ElementType *Element)
 Draws the name of an element.
void DrawElementPackage (ElementType *Element)
 Draws the package of an element.
void DrawElementPinsAndPads (ElementType *Element)
 Draw pins of an element.
void EraseVia (PinType *Via)
 Erase a via.
void EraseRat (RatType *Rat)
 Erase a ratline.
void EraseViaName (PinType *Via)
 Erase a via name.
void ErasePad (PadType *Pad)
 Erase a pad object.
void ErasePadName (PadType *Pad)
 Erase a pad name.
void ErasePin (PinType *Pin)
 Erase a pin object.
void ErasePinName (PinType *Pin)
 Erase a pin name.
void EraseLine (LineType *Line)
 Erases a line on a layer.
void EraseArc (ArcType *Arc)
 Erases an arc on a layer.
void EraseText (LayerType *Layer, TextType *Text)
 Erases a text on a layer.
void ErasePolygon (PolygonType *Polygon)
 Erases a polygon on a layer.
void EraseElement (ElementType *Element)
 Erases an element.
void EraseElementPinsAndPads (ElementType *Element)
 Erases all pins and pads of an element.
void EraseElementName (ElementType *Element)
 Erases the name of an element.
void EraseObject (int type, void *lptr, void *ptr)
void DrawObject (int type, void *ptr1, void *ptr2)
static void draw_element (ElementType *element)
void hid_expose_callback (HID *hid, BoxType *region, void *item)
 HID drawing callback.

Variables

static BoxType Block = {MAXINT, MAXINT, -MAXINT, -MAXINT}
static int doing_pinout = 0
static bool doing_assy = false
static int current_layergroup

Detailed Description

Drawing routines.


Copyright.


PCB, interactive printed circuit board design

Copyright (C) 1994,1995,1996, 2003, 2004 Thomas Nau

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.

Contact addresses for paper mail and Email: Thomas Nau, Schlehenweg 15, 88471 Baustetten, Germany Thomas.Nau@rz.uni-ulm.de

Definition in file draw.c.


Define Documentation

#define LARGE_TEXT_SIZE   3

Definition at line 68 of file draw.c.

#define MAXINT   (((unsigned int)(~0))>>1)

Definition at line 62 of file draw.c.

Referenced by Draw().

#define N_TEXT_SIZES   4

Definition at line 69 of file draw.c.

#define NORMAL_TEXT_SIZE   2

Definition at line 67 of file draw.c.

#define SMALL_SMALL_TEXT_SIZE   0

Definition at line 65 of file draw.c.

#define SMALL_TEXT_SIZE   1

Definition at line 66 of file draw.c.


Function Documentation

static void _draw_pad ( hidGC  gc,
PadType pad,
bool  clear,
bool  mask 
) [static]
static void AddPart ( void *  b) [static]
static int arc_callback ( const BoxType b,
void *  cl 
) [static]

Definition at line 551 of file draw.c.

References hid_draw_st::draw_pcb_arc, OutputType::fgGC, hid_st::graphics, gui, layer, Output, and set_layer_object_color().

Referenced by DrawLayer().

Here is the call graph for this function:

static int clearPad_callback ( const BoxType b,
void *  cl 
) [static]

Definition at line 914 of file draw.c.

References _draw_pad(), pad_st::Mask, ON_SIDE, Output, and OutputType::pmGC.

Referenced by DrawMask(), and DrawSilk().

Here is the call graph for this function:

static int clearPin_callback ( const BoxType b,
void *  cl 
) [static]
void Draw ( void  )

Initiate the actual redrawing of the updated area.

Definition at line 130 of file draw.c.

References gui, hid_st::invalidate_lr, MAXINT, BoxType::X1, BoxType::X2, BoxType::Y1, and BoxType::Y2.

Referenced by ActionAddRats(), ActionChangeName(), ActionConnection(), ActionDisplay(), ActionFlip(), ActionMorphPolygon(), ActionSelect(), ActionSetThermal(), ActionToggleHideName(), ActionUnselect(), AddAllRats(), ChangeHole(), ChangeObject2ndSize(), ChangeObjectClearSize(), ChangeObjectJoin(), ChangeObjectMaskSize(), ChangeObjectName(), ChangeObjectOctagon(), ChangeObjectSize(), ChangeObjectSquare(), ChangeObjectThermal(), ChangeObjectViaLayers(), ChangePaste(), ChangeSelected2ndSize(), ChangeSelectedClearSize(), ChangeSelectedElementSide(), ChangeSelectedHole(), ChangeSelectedJoin(), ChangeSelectedOctagon(), ChangeSelectedPaste(), ChangeSelectedSize(), ChangeSelectedSquare(), ChangeSelectedThermals(), ChangeSelectedViaLayers(), ClearWarnings(), ClosePolygon(), ClrObjectJoin(), ClrObjectOctagon(), ClrObjectSquare(), ClrSelectedJoin(), ClrSelectedOctagon(), ClrSelectedSquare(), CopyPastebufferToLayout(), DeleteRats(), DoIt(), DRCAll(), escape(), InsertPointIntoLine(), InsertPointIntoPolygon(), InsertPointIntoRat(), LookupConnection(), LookupElementConnections(), LookupUnusedPins(), MoveArc(), MoveArcToLayer(), MoveElement(), MoveElementName(), MoveLine(), MoveLinePoint(), MoveLineToLayer(), MovePolygon(), MovePolygonPoint(), MovePolygonToLayer(), MoveRatToLayer(), MoveText(), MoveTextToLayer(), MoveVia(), nbcb_select_common(), netlist_select_cb(), NotifyMode(), QueryInputAndChangeObjectName(), Redo(), RemoveArc(), RemoveElement(), RemoveLine(), RemovePolygon(), RemovePolygonContour(), RemovePolygonPoint(), RemoveRat(), RemoveSelected(), RemoveText(), RemoveVia(), RotateArc(), RotateElement(), RotateElementName(), RotateLinePoint(), RotateObject(), RotateText(), RouteAll(), SelectBlock(), selection_changed_cb(), SelectObject(), SetMode(), SetObjectJoin(), SetObjectOctagon(), SetObjectSquare(), SetSelectedJoin(), SetSelectedOctagon(), SetSelectedSquare(), TracePath(), and Undo().

static void draw_element ( ElementType element) [static]

Definition at line 1659 of file draw.c.

References draw_element_name(), draw_element_package(), and draw_element_pins_and_pads().

Referenced by hid_expose_callback().

Here is the call graph for this function:

static void draw_element_pins_and_pads ( ElementType element) [static]

Definition at line 390 of file draw.c.

References doing_assy, doing_pinout, draw_pad(), draw_pin(), END_LOOP, FRONT, PCBType::InvisibleObjectsOn, PAD_LOOP, PCB, pin, and PIN_LOOP.

Referenced by draw_element().

Here is the call graph for this function:

static void draw_pin ( PinType pin,
bool  draw_hole 
) [static]
static void draw_via ( PinType via,
bool  draw_hole 
) [static]
void DrawArc ( LayerType Layer,
ArcType Arc 
)
void DrawElement ( ElementType Element)

Draws an element.

Definition at line 1342 of file draw.c.

References DrawElementName(), DrawElementPackage(), and DrawElementPinsAndPads().

Referenced by ChangeElementSide(), ChangeElementSize(), DrawObject(), DRCAll(), NotifyMode(), RotateElement(), SelectBlock(), and UndoMirror().

Here is the call graph for this function:

void DrawElementName ( ElementType Element)

Draws the name of an element.

Definition at line 1353 of file draw.c.

References DrawText(), ELEMENT_TEXT, PCB, and TEST_FLAG.

Referenced by ActionDisplay(), ActionToggleHideName(), ChangeElementNameSize(), ChangeElementText(), CopyElement(), DrawElement(), DrawObject(), MoveElement(), MoveElementName(), NotifyMode(), RotateElementName(), SelectBlock(), and SelectObject().

Here is the call graph for this function:

void DrawElementPackage ( ElementType Element)

Draws the package of an element.

Definition at line 1364 of file draw.c.

References ARC_LOOP, DrawArc(), DrawLine(), ELEMENTLINE_LOOP, END_LOOP, and line.

Referenced by CopyElement(), DrawElement(), MoveElement(), and SelectObject().

Here is the call graph for this function:

void DrawElementPinsAndPads ( ElementType Element)

Draw pins of an element.

Definition at line 1382 of file draw.c.

References doing_assy, doing_pinout, DrawPad(), DrawPin(), END_LOOP, FRONT, PCBType::InvisibleObjectsOn, PAD_LOOP, PCB, pin, and PIN_LOOP.

Referenced by CopyElement(), DrawElement(), MoveElement(), and SelectObject().

Here is the call graph for this function:

void DrawHoles ( bool  draw_plated,
bool  draw_unplated,
const BoxType drawn_area,
Cardinal  g_from,
Cardinal  g_to 
)

Definition at line 498 of file draw.c.

References current_layergroup, PCBType::Data, hole_callback(), PCB, DataType::pin_tree, hole_info::plated, r_search(), and DataType::via_tree.

Referenced by DrawEverything().

Here is the call graph for this function:

void DrawLayerGroup ( int  group,
const BoxType drawn_area 
)

Draws one layer group.

If the exporter is not a GUI, also draws the pins / pads / vias in this layer group.

Definition at line 1128 of file draw.c.

References PCBType::Data, DrawLayer(), DrawPPV(), LayerGroupType::Entries, hid_st::gui, gui, DataType::Layer, Layer, PCBType::LayerGroups, layers, LayerType::Name, LayerGroupType::Number, and PCB.

Referenced by DrawEverything(), and PrintAssembly().

Here is the call graph for this function:

void DrawMask ( int  side,
const BoxType screen 
)
void DrawPadName ( PadType Pad)

Draws the name of a pad.

Definition at line 1271 of file draw.c.

References GatherPadName().

Referenced by ActionDisplay(), ChangePadName(), and DrawPad().

Here is the call graph for this function:

void DrawPaste ( int  side,
const BoxType drawn_area 
)

Draws solder paste layer for a given side of the board.

Definition at line 1015 of file draw.c.

References _draw_pad(), ALLPAD_LOOP, COORD_TO_MM, PCBType::Data, PCBType::ElementColor, ENDALL_LOOP, OutputType::fgGC, hid_st::graphics, gui, ON_SIDE, Output, SettingType::PasteAdjust, PCB, hid_draw_st::set_color, Settings, and TEST_FLAG.

Referenced by DrawEverything().

Here is the call graph for this function:

void DrawPinName ( PinType Pin)

Draws the name of a pin.

Definition at line 1251 of file draw.c.

References GatherPVName().

Referenced by ActionDisplay(), ChangePinName(), ChangeViaName(), and DrawPin().

Here is the call graph for this function:

static void DrawPPV ( int  group,
const BoxType drawn_area 
) [static]

Draws pins pads and vias - Always draws for non-gui HIDs, otherwise drawing depends on PCB->PinOn and PCB->ViaOn.

Definition at line 846 of file draw.c.

References bottom_group, BOTTOM_SIDE, current_layergroup, PCBType::Data, doing_assy, GetLayerGroupNumberBySide(), hid_st::gui, gui, hole_callback(), pad_callback(), DataType::pad_tree, PCB, pin_callback(), DataType::pin_tree, PCBType::PinOn, r_search(), top_group, TOP_SIDE, via_callback(), DataType::via_tree, and PCBType::ViaOn.

Referenced by DrawEverything(), and DrawLayerGroup().

Here is the call graph for this function:

static void DrawRats ( const BoxType drawn_area) [static]

Definition at line 1050 of file draw.c.

References PCBType::Data, hid_st::graphics, gui, HID_MASK_CLEAR, HID_MASK_OFF, hid_st::name, PCB, r_search(), rat_callback(), DataType::rat_tree, and hid_draw_st::use_mask.

Referenced by DrawEverything().

Here is the call graph for this function:

void DrawText ( LayerType Layer,
TextType Text 
)

Draws a text on a layer.

Definition at line 1323 of file draw.c.

References AddPart().

Referenced by ChangeTextJoin(), ChangeTextName(), ChangeTextSize(), CopyText(), DrawElementName(), DrawObject(), MoveText(), MoveTextToLayer(), NotifyMode(), RotateText(), SelectBlock(), and SelectObject().

Here is the call graph for this function:

void DrawViaName ( PinType Via)

Draws the name of a via.

Definition at line 1230 of file draw.c.

References GatherPVName().

Referenced by ActionDisplay(), and DrawVia().

Here is the call graph for this function:

static int element_callback ( const BoxType b,
void *  cl 
) [static]

Definition at line 589 of file draw.c.

References draw_element_package(), and ON_SIDE.

Referenced by DrawEverything(), and DrawSilk().

Here is the call graph for this function:

static int EMark_callback ( const BoxType b,
void *  cl 
) [static]

Definition at line 406 of file draw.c.

References DrawEMark(), FRONT, ElementType::MarkX, and ElementType::MarkY.

Referenced by DrawEverything().

Here is the call graph for this function:

void EraseArc ( ArcType Arc)

Erases an arc on a layer.

Definition at line 1493 of file draw.c.

References AddPart(), and ArcType::Thickness.

Referenced by ChangeArcClearSize(), ChangeArcJoin(), ChangeArcSize(), EraseElement(), EraseObject(), MoveArc(), MoveArcToLayer(), RemoveArc(), and RotateArc().

Here is the call graph for this function:

void EraseElement ( ElementType Element)

Erases an element.

Definition at line 1523 of file draw.c.

References ARC_LOOP, ELEMENTLINE_LOOP, END_LOOP, EraseArc(), EraseElementName(), EraseElementPinsAndPads(), EraseLine(), and line.

Referenced by ChangeElementSide(), ChangeElementSize(), EraseObject(), MoveElement(), RemoveElement(), RotateElement(), and UndoMirror().

Here is the call graph for this function:

void EraseElementName ( ElementType Element)

Erases the name of an element.

Definition at line 1561 of file draw.c.

References ELEMENT_TEXT, EraseText(), PCB, and TEST_FLAG.

Referenced by ActionDisplay(), ActionToggleHideName(), ChangeElementNameSize(), ChangeElementText(), EraseElement(), EraseObject(), MoveElementName(), NotifyMode(), and RotateElementName().

Here is the call graph for this function:

void EraseElementPinsAndPads ( ElementType Element)

Erases all pins and pads of an element.

Definition at line 1543 of file draw.c.

References END_LOOP, ErasePad(), ErasePin(), PAD_LOOP, pin, and PIN_LOOP.

Referenced by EraseElement(), and MoveElement().

Here is the call graph for this function:

void EraseLine ( LineType Line)

Erases a line on a layer.

Definition at line 1484 of file draw.c.

References AddPart().

Referenced by ChangeLineClearSize(), ChangeLineJoin(), ChangeLineSize(), EraseElement(), EraseObject(), EraseRat(), InsertPointIntoLine(), MoveLine(), MoveLinePoint(), MoveLineToLayer(), RemoveLine(), ripout_livedraw_obj(), RotateLinePoint(), and RotateObject().

Here is the call graph for this function:

void EraseObject ( int  type,
void *  lptr,
void *  ptr 
)
void ErasePad ( PadType Pad)

Erase a pad object.

Definition at line 1444 of file draw.c.

References AddPart(), ErasePadName(), and TEST_FLAG.

Referenced by ChangePadClearSize(), ChangePadMaskSize(), ChangePadSize(), ChangePadSquare(), ChangePaste(), EraseElementPinsAndPads(), and EraseObject().

Here is the call graph for this function:

void ErasePadName ( PadType Pad)

Erase a pad name.

Definition at line 1455 of file draw.c.

References GatherPadName().

Referenced by ActionDisplay(), ChangePadName(), and ErasePad().

Here is the call graph for this function:

void ErasePin ( PinType Pin)

Erase a pin object.

Definition at line 1464 of file draw.c.

References AddPart(), ErasePinName(), and TEST_FLAG.

Referenced by ChangeElement2ndSize(), ChangePin2ndSize(), ChangePinClearSize(), ChangePinMaskSize(), ChangePinOctagon(), ChangePinSize(), ChangePinSquare(), EraseElementPinsAndPads(), and EraseObject().

Here is the call graph for this function:

void ErasePinName ( PinType Pin)

Erase a pin name.

Definition at line 1475 of file draw.c.

References GatherPVName().

Referenced by ActionDisplay(), ChangePinName(), ChangeViaName(), and ErasePin().

Here is the call graph for this function:

void ErasePolygon ( PolygonType Polygon)

Erases a polygon on a layer.

Definition at line 1514 of file draw.c.

References AddPart().

Referenced by EraseObject(), InsertPointIntoPolygon(), MorphPolygon(), MovePolygon(), MovePolygonPoint(), MovePolygonToLayer(), RemovePolygon(), RemovePolygonContour(), RemovePolygonPoint(), UndoInsertPoint(), and UndoRemovePoint().

Here is the call graph for this function:

void EraseRat ( RatType Rat)

Erase a ratline.

Definition at line 1412 of file draw.c.

References AddPart(), EraseLine(), TEST_FLAG, BoxType::X1, BoxType::X2, BoxType::Y1, and BoxType::Y2.

Referenced by ActionChangeName(), InsertPointIntoRat(), MoveLinePoint(), MoveRatToLayer(), NotifyMode(), and RemoveRat().

Here is the call graph for this function:

void EraseText ( LayerType Layer,
TextType Text 
)

Erases a text on a layer.

Definition at line 1504 of file draw.c.

References AddPart().

Referenced by ChangeTextJoin(), ChangeTextName(), ChangeTextSize(), EraseElementName(), EraseObject(), MoveText(), MoveTextToLayer(), RemoveText(), and RotateText().

Here is the call graph for this function:

void EraseVia ( PinType Via)

Erase a via.

Definition at line 1401 of file draw.c.

References AddPart(), EraseViaName(), and TEST_FLAG.

Referenced by ChangeHole(), ChangeVia2ndSize(), ChangeViaClearSize(), ChangeViaMaskSize(), ChangeViaOctagon(), ChangeViaSize(), MoveVia(), RemoveVia(), and ripout_livedraw_obj().

Here is the call graph for this function:

void EraseViaName ( PinType Via)

Erase a via name.

Definition at line 1435 of file draw.c.

References GatherPVName().

Referenced by ActionDisplay(), and EraseVia().

Here is the call graph for this function:

static void GatherPadName ( PadType Pad) [static]

Definition at line 1184 of file draw.c.

References AddPart(), box, MAX, MIN, SettingType::PinoutTextOffsetX, SettingType::PinoutTextOffsetY, Settings, BoxType::X1, BoxType::X2, BoxType::Y1, and BoxType::Y2.

Referenced by DrawPadName(), and ErasePadName().

Here is the call graph for this function:

static void GatherPVName ( PinType Ptr) [static]
void hid_expose_callback ( HID hid,
BoxType region,
void *  item 
)
static int line_callback ( const BoxType b,
void *  cl 
) [static]

Definition at line 512 of file draw.c.

References hid_draw_st::draw_pcb_line, OutputType::fgGC, hid_st::graphics, gui, layer, line, Output, and set_layer_object_color().

Referenced by DrawLayer().

Here is the call graph for this function:

static int name_callback ( const BoxType b,
void *  cl 
) [static]

Definition at line 375 of file draw.c.

References draw_element_name(), TextType::Element, ON_SIDE, and TEST_FLAG.

Referenced by DrawEverything(), and DrawSilk().

Here is the call graph for this function:

static int pad_callback ( const BoxType b,
void *  cl 
) [static]

Definition at line 347 of file draw.c.

References draw_pad(), and ON_SIDE.

Referenced by DrawEverything(), and DrawPPV().

Here is the call graph for this function:

static int pin_callback ( const BoxType b,
void *  cl 
) [static]

Definition at line 236 of file draw.c.

References draw_pin().

Referenced by DrawPPV().

Here is the call graph for this function:

static int poly_callback ( const BoxType b,
void *  cl 
) [static]

Definition at line 901 of file draw.c.

References hid_draw_st::draw_pcb_polygon, poly_info::drawn_area, OutputType::fgGC, hid_st::graphics, gui, poly_info::layer, Output, and set_layer_object_color().

Referenced by DrawLayer().

Here is the call graph for this function:

void PrintAssembly ( int  side,
const BoxType drawn_area 
)

Prints assembly drawing.

Definition at line 603 of file draw.c.

References doing_assy, DrawLayerGroup(), DrawSilk(), OutputType::fgGC, GetLayerGroupNumberBySide(), hid_st::graphics, gui, Output, and hid_draw_st::set_draw_faded.

Referenced by DrawEverything().

Here is the call graph for this function:

static int rat_callback ( const BoxType b,
void *  cl 
) [static]
void Redraw ( void  )
static void set_layer_object_color ( LayerType layer,
AnyObjectType obj 
) [static]

Definition at line 107 of file draw.c.

References LayerType::Color, PCBType::ConnectedColor, PCBType::FoundColor, PCB, LayerType::SelectedColor, and set_object_color().

Referenced by arc_callback(), line_callback(), and poly_callback().

Here is the call graph for this function:

static void set_object_color ( AnyObjectType obj,
char *  warn_color,
char *  selected_color,
char *  connected_color,
char *  found_color,
char *  normal_color 
) [static]
static int text_callback ( const BoxType b,
void *  cl 
) [static]
static int via_callback ( const BoxType b,
void *  cl 
) [static]

Definition at line 265 of file draw.c.

References draw_via(), and via_visible_on_layer_group().

Referenced by DrawPPV().

Here is the call graph for this function:

static bool via_visible_on_layer_group ( PinType via) [static]

Definition at line 256 of file draw.c.

References current_layergroup, and ViaIsOnLayerGroup().

Referenced by hole_callback(), and via_callback().

Here is the call graph for this function:


Variable Documentation

BoxType Block = {MAXINT, MAXINT, -MAXINT, -MAXINT} [static]

Definition at line 75 of file draw.c.

int current_layergroup [static]

Definition at line 80 of file draw.c.

Referenced by DrawHoles(), DrawPPV(), and via_visible_on_layer_group().