PCB-FPW developer documentation based on version: 0.0.11

Functions | Variables

select_exceptions.c File Reference

A widget for selecting exception pin/pads in an array type footprint. More...

Go to the source code of this file.

Functions

static void select_exceptions_clear_cb (GtkWidget *widget, GtkWidget *window)
 The "Clear" button is clicked.
static void select_exceptions_close_cb (GtkWidget *widget, GtkWidget *window)
 The "Close" button is clicked.
static void select_exceptions_delete_event (GtkWidget *widget, GdkEvent *event)
 Delete the window.
static void select_exceptions_ok_cb (GtkWidget *widget, GtkWidget *window)
 The "OK" button is clicked.
static void select_exceptions_selection_button_clicked_cb (GtkWidget *widget, GtkWidget *window)
 One of the selection buttons is clicked.
int select_exceptions_create_window (gint number_of_rows, gint number_of_columns)
 Create a selection exceptions window.

Variables

static SelectionButtonSet selection_buttons [MAX_ROWS *MAX_COLUMNS]
GtkWidget * select_exceptions_window = NULL

Detailed Description

A widget for selecting exception pin/pads in an array type footprint.

Author:
Copyright (C) 2007, 2008, 2009, 2010 by Bert Timmerman <bert.timmerman@xs4all.nl>

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.

Definition in file select_exceptions.c.


Function Documentation

static void select_exceptions_clear_cb ( GtkWidget *  widget,
GtkWidget *  window 
) [static]

The "Clear" button is clicked.

  • set the "active" field of all the selection_buttons members to TRUE.
  • set all selection buttons in the GUI to the active state.
Parameters:
widget : is the caller widget.
window : is the window widget.

Definition at line 44 of file select_exceptions.c.

References SelectionButtonSet::active, SelectionButtonSet::button_widget, number_of_columns, number_of_rows, and pin_pad_exceptions_string.

Referenced by select_exceptions_create_window().

static void select_exceptions_close_cb ( GtkWidget *  widget,
GtkWidget *  window 
) [static]

The "Close" button is clicked.

  • close the window (destroy the widget).
  • reset the pointer value of the select exceptions window (global).
Parameters:
widget : is the caller widget.
window : is the window widget to close (destroy).

Definition at line 95 of file select_exceptions.c.

Referenced by select_exceptions_create_window().

int select_exceptions_create_window ( gint  number_of_rows,
gint  number_of_columns 
)

Create a selection exceptions window.

  • create only one single window with a title "select exceptions".
  • depending on the package type create the pattern of selection buttons.
  • add "Close", "Clear" and "OK" stock buttons.
Returns:
EXIT_SUCCESS when the function is completed.
Parameters:
number_of_rows : is the number of pin/pad rows (selection buttons).
number_of_columns : is the number of pin/pad columns (selection buttons).

Definition at line 244 of file select_exceptions.c.

References SelectionButtonSet::active, SelectionButtonSet::button_widget, get_pin_pad_exception(), SelectionButtonSet::id, SelectionButtonSet::name, row_letters, select_exceptions_clear_cb(), select_exceptions_close_cb(), select_exceptions_delete_event(), select_exceptions_ok_cb(), and select_exceptions_selection_button_clicked_cb().

Here is the call graph for this function:

static void select_exceptions_delete_event ( GtkWidget *  widget,
GdkEvent *  event 
) [static]

Delete the window.

  • close the window (destroy the widget).
  • reset the pointer value of the select exceptions window (global).
Parameters:
widget : is the caller widget.
event : is the event passed from the caller.

Definition at line 117 of file select_exceptions.c.

Referenced by select_exceptions_create_window().

static void select_exceptions_ok_cb ( GtkWidget *  widget,
GtkWidget *  window 
) [static]

The "OK" button is clicked.

  • save the state of all selection buttons.
  • collect all the exceptions in the pin_pad_exception_string (global).
  • close the window (destroy the widget).
  • reset the pointer value of the select exceptions window (global).
Parameters:
widget : is the caller widget (the OK button).
window : is the window widget to close (destroy).

Definition at line 142 of file select_exceptions.c.

References SelectionButtonSet::active, SelectionButtonSet::name, number_of_columns, number_of_exceptions, number_of_rows, pin_pad_exceptions_string, row_letters, and verbose.

Referenced by select_exceptions_create_window().

static void select_exceptions_selection_button_clicked_cb ( GtkWidget *  widget,
GtkWidget *  window 
) [static]

One of the selection buttons is clicked.

  • lookup the selection button in the array selection_button.
  • save the state of the selection button in selection_button->active.
Parameters:
widget : is the caller widget (the clicked button).
window : is the parent window widget of the clicked button).

Definition at line 209 of file select_exceptions.c.

References SelectionButtonSet::active, and SelectionButtonSet::name.

Referenced by select_exceptions_create_window().