pcb 4.1.1
An interactive printed circuit board layout editor.
|
#include <glib.h>
#include <glib-object.h>
#include <gtk/gtk.h>
#include "global.h"
Go to the source code of this file.
Defines | |
#define | GHID_ROUTE_STYLE_SELECTOR_TYPE (ghid_route_style_selector_get_type ()) |
#define | GHID_ROUTE_STYLE_SELECTOR(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GHID_ROUTE_STYLE_SELECTOR_TYPE, GHidRouteStyleSelector)) |
#define | GHID_ROUTE_STYLE_SELECTOR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GHID_ROUTE_STYLE_SELECTOR_TYPE, GHidRouteStyleSelectorClass)) |
#define | IS_GHID_ROUTE_STYLE_SELECTOR(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GHID_ROUTE_STYLE_SELECTOR_TYPE)) |
#define | IS_GHID_ROUTE_STYLE_SELECTOR_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GHID_ROUTE_STYLE_SELECTOR_TYPE)) |
Typedefs | |
typedef struct _GHidRouteStyleSelector | GHidRouteStyleSelector |
typedef struct _GHidRouteStyleSelectorClass | GHidRouteStyleSelectorClass |
Functions | |
GType | ghid_route_style_selector_get_type (void) |
GtkWidget * | ghid_route_style_selector_new (void) |
Create a new GHidRouteStyleSelector. | |
gint | ghid_route_style_selector_install_items (GHidRouteStyleSelector *rss, GtkMenuShell *shell, gint pos) |
Install the "Route Style" menu items. | |
void | ghid_route_style_selector_add_route_style (GHidRouteStyleSelector *rss, RouteStyleType *data) |
Adds a route style to a GHidRouteStyleSelector. | |
gboolean | ghid_route_style_selector_select_style (GHidRouteStyleSelector *rss, RouteStyleType *rst) |
Selects a route style and emits a select-style signal. | |
void | ghid_route_style_selector_edit_dialog (GHidRouteStyleSelector *rss) |
GtkAccelGroup * | ghid_route_style_selector_get_accel_group (GHidRouteStyleSelector *rss) |
Returns the GtkAccelGroup of a route style selector. | |
void | ghid_route_style_selector_sync (GHidRouteStyleSelector *rss, Coord Thick, Coord Hole, Coord Diameter, Coord Keepaway) |
Sets a GHidRouteStyleSelector selection to given values. | |
void | ghid_route_style_selector_empty (GHidRouteStyleSelector *rss) |
Removes all styles from a route style selector. |
#define GHID_ROUTE_STYLE_SELECTOR | ( | obj | ) | (G_TYPE_CHECK_INSTANCE_CAST ((obj), GHID_ROUTE_STYLE_SELECTOR_TYPE, GHidRouteStyleSelector)) |
Definition at line 13 of file ghid-route-style-selector.h.
Referenced by AdjustStyle(), ghid_build_pcb_top_window(), ghid_do_export(), ghid_install_accel_groups(), ghid_remove_accel_groups(), ghid_sync_with_new_layout(), make_route_style_buttons(), PCBChanged(), route_styles_edited_cb(), and RouteStylesChanged().
#define GHID_ROUTE_STYLE_SELECTOR_CLASS | ( | klass | ) | (G_TYPE_CHECK_CLASS_CAST ((klass), GHID_ROUTE_STYLE_SELECTOR_TYPE, GHidRouteStyleSelectorClass)) |
Definition at line 14 of file ghid-route-style-selector.h.
#define GHID_ROUTE_STYLE_SELECTOR_TYPE (ghid_route_style_selector_get_type ()) |
Definition at line 12 of file ghid-route-style-selector.h.
Referenced by ghid_route_style_selector_new().
#define IS_GHID_ROUTE_STYLE_SELECTOR | ( | obj | ) | (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GHID_ROUTE_STYLE_SELECTOR_TYPE)) |
Definition at line 15 of file ghid-route-style-selector.h.
#define IS_GHID_ROUTE_STYLE_SELECTOR_CLASS | ( | klass | ) | (G_TYPE_CHECK_CLASS_TYPE ((klass), GHID_ROUTE_STYLE_SELECTOR_TYPE)) |
Definition at line 16 of file ghid-route-style-selector.h.
typedef struct _GHidRouteStyleSelector GHidRouteStyleSelector |
Definition at line 18 of file ghid-route-style-selector.h.
typedef struct _GHidRouteStyleSelectorClass GHidRouteStyleSelectorClass |
Definition at line 19 of file ghid-route-style-selector.h.
void ghid_route_style_selector_add_route_style | ( | GHidRouteStyleSelector * | rss, |
RouteStyleType * | data | ||
) |
Adds a route style to a GHidRouteStyleSelector.
[in] | rss | The selector to be acted on |
[in] | data | PCB's route style object describing the style |
Definition at line 497 of file ghid-route-style-selector.c.
References FALSE, and ghid_route_style_selector_real_add_route_style().
Referenced by make_route_style_buttons().
void ghid_route_style_selector_edit_dialog | ( | GHidRouteStyleSelector * | rss | ) |
Definition at line 170 of file ghid-route-style-selector.c.
References _, _table_attach(), _route_style::action, _GHidRouteStyleSelector::active_style, _dialog::clearance_entry, DATA_COL, dialog_style_changed_cb(), RouteStyleType::Diameter, FALSE, ghid_category_vbox(), GHID_COORD_ENTRY, ghid_coord_entry_get_value(), ghid_route_style_selector_real_add_route_style(), ghid_route_style_selector_select_style(), ghid_route_style_selector_signals, RouteStyleType::Hole, RouteStyleType::Keepaway, _dialog::line_entry, _GHidRouteStyleSelector::model, RouteStyleType::Name, _dialog::name_entry, _route_style::rref, _dialog::rss, _route_style::rst, StripWhiteSpaceAndDup(), style, STYLE_EDITED_SIGNAL, TEXT_COL, RouteStyleType::Thick, TRUE, _dialog::via_hole_entry, _dialog::via_size_entry, and window.
Referenced by AdjustStyle(), and edit_button_cb().
void ghid_route_style_selector_empty | ( | GHidRouteStyleSelector * | rss | ) |
Removes all styles from a route style selector.
Definition at line 638 of file ghid-route-style-selector.c.
References _route_style::action, _GHidRouteStyleSelector::action_group, _GHidRouteStyleSelector::action_radio_group, _route_style::button, _GHidRouteStyleSelector::button_radio_group, DATA_COL, init_radio_groups(), _route_style::menu_item, _GHidRouteStyleSelector::model, RouteStyleType::Name, _route_style::rref, _route_style::rst, _GHidRouteStyleSelector::shortcut_key_idx, and _route_style::temporary.
Referenced by ghid_route_style_selector_finalize(), and PCBChanged().
GtkAccelGroup* ghid_route_style_selector_get_accel_group | ( | GHidRouteStyleSelector * | rss | ) |
Returns the GtkAccelGroup of a route style selector.
[in] | rss | The selector to be acted on |
Definition at line 586 of file ghid-route-style-selector.c.
References _GHidRouteStyleSelector::accel_group.
Referenced by ghid_install_accel_groups(), and ghid_remove_accel_groups().
GType ghid_route_style_selector_get_type | ( | void | ) |
Definition at line 363 of file ghid-route-style-selector.c.
References ghid_route_style_selector_class_init(), and ghid_route_style_selector_init().
gint ghid_route_style_selector_install_items | ( | GHidRouteStyleSelector * | rss, |
GtkMenuShell * | shell, | ||
gint | pos | ||
) |
Install the "Route Style" menu items.
[in] | rss | The selector to be acted on |
[in] | shell | The menu to install the items in |
[in] | pos | The position in the menu to install items |
Definition at line 518 of file ghid-route-style-selector.c.
References _route_style::action, action, DATA_COL, _route_style::menu_item, _GHidRouteStyleSelector::model, n, and style.
Referenced by ghid_main_menu_install_route_style_selector().
GtkWidget* ghid_route_style_selector_new | ( | void | ) |
Create a new GHidRouteStyleSelector.
Definition at line 396 of file ghid-route-style-selector.c.
References _, _GHidRouteStyleSelector::accel_group, _GHidRouteStyleSelector::action_group, _GHidRouteStyleSelector::action_radio_group, _GHidRouteStyleSelector::active_style, _GHidRouteStyleSelector::button_radio_group, _GHidRouteStyleSelector::edit_button, edit_button_cb(), FALSE, GHID_ROUTE_STYLE_SELECTOR_TYPE, init_radio_groups(), _GHidRouteStyleSelector::model, N_COLS, _GHidRouteStyleSelector::null_action, _GHidRouteStyleSelector::null_button, and _GHidRouteStyleSelector::shortcut_key_idx.
Referenced by ghid_build_pcb_top_window().
gboolean ghid_route_style_selector_select_style | ( | GHidRouteStyleSelector * | rss, |
RouteStyleType * | rst | ||
) |
Selects a route style and emits a select-style signal.
[in] | rss | The selector to be acted on |
[in] | rst | The style to select |
Definition at line 550 of file ghid-route-style-selector.c.
References _route_style::action, _GHidRouteStyleSelector::active_style, DATA_COL, FALSE, ghid_route_style_selector_signals, _GHidRouteStyleSelector::model, _route_style::rst, SELECT_STYLE_SIGNAL, _route_style::sig_id, style, and TRUE.
Referenced by ghid_route_style_selector_edit_dialog(), and ghid_sync_with_new_layout().
void ghid_route_style_selector_sync | ( | GHidRouteStyleSelector * | rss, |
Coord | Thick, | ||
Coord | Hole, | ||
Coord | Diameter, | ||
Coord | Keepaway | ||
) |
Sets a GHidRouteStyleSelector selection to given values.
[in] | rss | The selector to be acted on |
[in] | Thick | Coord to match selection to |
[in] | Hole | Coord to match selection to |
[in] | Diameter | Coord to match selection to |
[in] | Keepaway | Coord to match selection to |
Definition at line 605 of file ghid-route-style-selector.c.
References _route_style::action, _GHidRouteStyleSelector::active_style, DATA_COL, RouteStyleType::Diameter, FALSE, RouteStyleType::Hole, RouteStyleType::Keepaway, _GHidRouteStyleSelector::model, _GHidRouteStyleSelector::null_action, _route_style::rst, _route_style::sig_id, style, RouteStyleType::Thick, and TRUE.
Referenced by RouteStylesChanged().