pcb 4.1.1
An interactive printed circuit board layout editor.
|
Select routines. More...
#include "global.h"
#include "data.h"
#include "draw.h"
#include "error.h"
#include "search.h"
#include "select.h"
#include "undo.h"
#include "rats.h"
#include "misc.h"
#include "find.h"
#include <sys/types.h>
Go to the source code of this file.
Functions | |
bool | SelectObject (void) |
Toggles the selection of any kind of object. | |
bool | SelectBlock (BoxType *Box, bool select) |
Selects/unselects all visible objects within the passed box. | |
void * | ObjectOperation (ObjectFunctionType *F, int Type, void *Ptr1, void *Ptr2, void *Ptr3) |
Performs several operations on the passed object. | |
bool | SelectedOperation (ObjectFunctionType *F, bool Reset, int type) |
Performs several operations on selected objects which are also visible. | |
bool | SelectByFlag (int flag, bool select) |
Selects/unselects all objects which have (any of) the specified flag(s) set. | |
bool | SelectBuriedVias (bool select) |
Selects all blind/buried vias. |
Select routines.
PCB, interactive printed circuit board design
Copyright (C) 1994,1995,1996 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
Definition in file select.c.
void* ObjectOperation | ( | ObjectFunctionType * | F, |
int | Type, | ||
void * | Ptr1, | ||
void * | Ptr2, | ||
void * | Ptr3 | ||
) |
Performs several operations on the passed object.
Definition at line 449 of file select.c.
References ObjectFunctionType::Arc, ObjectFunctionType::Element, ObjectFunctionType::ElementName, ObjectFunctionType::Line, ObjectFunctionType::LinePoint, ObjectFunctionType::Pad, ObjectFunctionType::Pin, ObjectFunctionType::Point, ObjectFunctionType::Polygon, ObjectFunctionType::Rat, ObjectFunctionType::Text, and ObjectFunctionType::Via.
Referenced by ChangeObject2ndSize(), ChangeObjectClearSize(), ChangeObjectJoin(), ChangeObjectMaskSize(), ChangeObjectName(), ChangeObjectOctagon(), ChangeObjectSize(), ChangeObjectSquare(), ChangeObjectThermal(), ClrObjectJoin(), ClrObjectOctagon(), ClrObjectSquare(), CopyObject(), CopyObjectToBuffer(), DestroyObject(), InsertPointIntoObject(), MoveObject(), MoveObjectAndRubberband(), MoveObjectToBuffer(), MoveObjectToLayer(), RemoveObject(), RotateObject(), SetObjectJoin(), SetObjectOctagon(), and SetObjectSquare().
bool SelectBlock | ( | BoxType * | Box, |
bool | select | ||
) |
Selects/unselects all visible objects within the passed box.
"select" determines if the block is to be selected or unselected.
Definition at line 224 of file select.c.
References AddObjectToFlagUndoList(), ARC_IN_BOX, ARC_LOOP, ASSIGN_FLAG, BOX_IN_BOX, PCBType::Data, Draw(), DrawArc(), DrawElement(), DrawElementName(), DrawLine(), DrawPad(), DrawPin(), DrawPolygon(), DrawRat(), DrawText(), DrawVia(), ELEMENT_IN_BOX, ELEMENT_LOOP, ELEMENT_TEXT, PCBType::ElementOn, ELEMENTTEXT_LOOP, END_LOOP, IncrementUndoSerialNumber(), PCBType::InvisibleObjectsOn, layer, LAYER_LOOP, line, LINE_IN_BOX, LINE_LOOP, max_copper_layer, PAD_IN_BOX, PAD_LOOP, PCB, pin, PIN_LOOP, PCBType::PinOn, POLYGON_IN_BOX, POLYGON_LOOP, RAT_LOOP, PCBType::RatOn, SILK_LAYER, SWAP_IDENT, TEST_FLAG, TEXT_IN_BOX, TEXT_IS_VISIBLE, TEXT_LOOP, VIA_LOOP, VIA_OR_PIN_IN_BOX, and PCBType::ViaOn.
Referenced by ActionSelect(), ActionUnselect(), click_cb(), and ReleaseMode().
bool SelectBuriedVias | ( | bool | select | ) |
Selects all blind/buried vias.
Definition at line 1027 of file select.c.
References AddObjectToFlagUndoList(), ASSIGN_FLAG, PCBType::Data, END_LOOP, PCB, TEST_FLAG, VIA_IS_BURIED, and VIA_LOOP.
Referenced by ActionSelect().
bool SelectByFlag | ( | int | flag, |
bool | select | ||
) |
Selects/unselects all objects which have (any of) the specified flag(s) set.
This is typically the FOUNDFLAG, assigned during a connection scan.
"select" determines if they are to be selected or unselected.
Definition at line 728 of file select.c.
References AddObjectToFlagUndoList(), ALLPAD_LOOP, ALLPIN_LOOP, ASSIGN_FLAG, PCBType::Data, DrawArc(), DrawLine(), DrawPad(), DrawPin(), DrawPolygon(), DrawRat(), DrawVia(), PCBType::ElementOn, END_LOOP, ENDALL_LOOP, layer, line, PCB, pin, PCBType::PinOn, RAT_LOOP, PCBType::RatOn, TEST_FLAG, VIA_LOOP, PCBType::ViaOn, VISIBLEARC_LOOP, VISIBLELINE_LOOP, and VISIBLEPOLYGON_LOOP.
Referenced by ActionSelect(), ActionUnselect(), nbcb_select_common(), and netlist_select_cb().
bool SelectedOperation | ( | ObjectFunctionType * | F, |
bool | Reset, | ||
int | type | ||
) |
Performs several operations on selected objects which are also visible.
The lowlevel procedures are passed together with additional information.
Resets the selected flag if requested.
Definition at line 531 of file select.c.
References AddObjectToFlagUndoList(), ALLTEXT_LOOP, ObjectFunctionType::Arc, CLEAR_FLAG, PCBType::Data, ObjectFunctionType::Element, ELEMENT_LOOP, ELEMENT_TEXT, ObjectFunctionType::ElementName, PCBType::ElementOn, END_LOOP, ENDALL_LOOP, IncrementUndoSerialNumber(), layer, line, ObjectFunctionType::Line, ObjectFunctionType::Pad, PAD_LOOP, PCB, pin, ObjectFunctionType::Pin, PIN_LOOP, PCBType::PinOn, ObjectFunctionType::Polygon, ObjectFunctionType::Rat, RAT_LOOP, PCBType::RatOn, TEST_FLAG, ObjectFunctionType::Text, TEXT_IS_VISIBLE, ObjectFunctionType::Via, VIA_LOOP, PCBType::ViaOn, VISIBLEARC_LOOP, VISIBLELINE_LOOP, and VISIBLEPOLYGON_LOOP.
Referenced by AddSelectedToBuffer(), ChangeSelected2ndSize(), ChangeSelectedClearSize(), ChangeSelectedJoin(), ChangeSelectedOctagon(), ChangeSelectedSize(), ChangeSelectedSquare(), ChangeSelectedThermals(), ClrSelectedJoin(), ClrSelectedOctagon(), ClrSelectedSquare(), MoveSelectedObjectsToLayer(), RemoveSelected(), SetSelectedJoin(), SetSelectedOctagon(), and SetSelectedSquare().
bool SelectObject | ( | void | ) |
Toggles the selection of any kind of object.
The various types are defined in search.h.
Definition at line 71 of file select.c.
References AddObjectToFlagUndoList(), Crosshair, Draw(), DrawArc(), DrawElementName(), DrawElementPackage(), DrawElementPinsAndPads(), DrawLine(), DrawPad(), DrawPin(), DrawPolygon(), DrawRat(), DrawText(), DrawVia(), PCBType::ElementOn, ELEMENTTEXT_LOOP, END_LOOP, IncrementUndoSerialNumber(), PCBType::InvisibleObjectsOn, layer, line, PAD_LOOP, PCB, pin, PIN_LOOP, PCBType::PinOn, poly, ptr1, ptr2, ptr3, SearchScreen(), SELECT_TYPES, SWAP_IDENT, TEST_FLAG, TOGGLE_FLAG, CrosshairType::X, and CrosshairType::Y.
Referenced by ActionSelect(), and ReleaseMode().