gschem

x_dialog.c File Reference

#include <config.h>
#include <version.h>
#include <missing.h>
#include <stdio.h>
#include "gschem.h"
Include dependency graph for x_dialog.c:

Go to the source code of this file.

Data Structures

struct  line_type_data
struct  fill_type_data
struct  _CloseConfirmationDialog
struct  _CloseConfirmationDialogClass

Defines

#define GLADE_HOOKUP_OBJECT(component, widget, name)
#define TYPE_CLOSE_CONFIRMATION_DIALOG   (close_confirmation_dialog_get_type ())
#define CLOSE_CONFIRMATION_DIALOG(obj)   (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_CLOSE_CONFIRMATION_DIALOG, CloseConfirmationDialog))
#define CLOSE_CONFIRMATION_DIALOG_CLASS(klass)   (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_CLOSE_CONFIRMATION_DIALOG, CloseConfirmationDialogClass))
#define IS_CLOSE_CONFIRMATION_DIALOG(obj)   (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_CLOSE_CONFIRMATION_DIALOG))
#define IS_CLOSE_CONFIRMATION_DIALOG_CLASS(klass)   (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_CLOSE_CONFIRMATION_DIALOG))
#define CLOSE_CONFIRMATION_DIALOG_GET_CLASS(obj)   (G_TYPE_INSTANCE_GET_CLASS ((obj),TYPE_CLOSE_CONFIRMATION_DIALOG, CloseConfirmationDialogClass))

Typedefs

typedef struct
_CloseConfirmationDialog 
CloseConfirmationDialog
typedef struct
_CloseConfirmationDialogClass 
CloseConfirmationDialogClass

Enumerations

enum  { PROP_UNSAVED_PAGE = 1, PROP_UNSAVED_PAGES, PROP_SELECTED_PAGES }
enum  { COLUMN_SAVE, COLUMN_PAGE, NUM_COLUMNS }

Functions

static GtkWidget * create_menu_linetype (GSCHEM_TOPLEVEL *w_current)
 Create a line type menu for the line type dialog.
static gint line_type_dialog_linetype_change (GtkWidget *w, gpointer data)
 Callback function for the linetype menu item in the line type dialog.
static void line_type_dialog_ok (GtkWidget *w, gpointer data)
 Worker function for the line type and width dialog.
static GtkWidget * create_menu_filltype (GSCHEM_TOPLEVEL *w_current)
 Create a menu with fill types for the line type dialog.
static gint fill_type_dialog_filltype_change (GtkWidget *w, gpointer data)
 Callback function for the filltype menu in the filltype dialog.
static void fill_type_dialog_ok (GtkWidget *w, gpointer data)
 Apply the settings of the filltype dialog to the selection.
void destroy_window (GtkWidget *widget, GtkWidget **window)
void text_input_dialog_apply (GtkWidget *w, GSCHEM_TOPLEVEL *w_current)
 worker function for the text entry dialog
void text_input_dialog_response (GtkWidget *widget, gint response, GSCHEM_TOPLEVEL *w_current)
 response function for the text entry dialog
void text_input_dialog (GSCHEM_TOPLEVEL *w_current)
 create or present the text entry dialog
gint change_alignment (GtkComboBox *w, GSCHEM_TOPLEVEL *w_current)
 CAllback for a text aligment change.
static GtkListStore * create_menu_alignment (GSCHEM_TOPLEVEL *w_current)
 Create the alignment combo box list store for the text property dialog.
static GtkWidget * create_color_menu (GSCHEM_TOPLEVEL *w_current)
 Create a ComboBox with the gschem colors.
void text_edit_dialog_ok (GtkWidget *w, GSCHEM_TOPLEVEL *w_current)
 Apply the settings from the text property dialog.
void text_edit_dialog_response (GtkWidget *widget, gint response, GSCHEM_TOPLEVEL *w_current)
 Response function for the text property dialog.
void text_edit_dialog (GSCHEM_TOPLEVEL *w_current, const char *string, int text_size, int text_alignment)
 Create the edit text properties dialog.
static gboolean selection_get_line_type (GList *selection, OBJECT_END *end, OBJECT_TYPE *type, gint *width, gint *length, gint *space)
 get the linetype data from selected objects
static void line_type_dialog_set_values (struct line_type_data *line_type_data, OBJECT_END end, OBJECT_TYPE type, gint width, gint length, gint space)
 set the linetype in the linetype dialog
void line_type_dialog_response (GtkWidget *widget, gint response, struct line_type_data *line_type_data)
 response function for the line type and width dialog
void line_type_dialog (GSCHEM_TOPLEVEL *w_current)
 Creates the line type and width dialog.
static gboolean selection_get_fill_type (GList *selection, OBJECT_FILLING *type, gint *width, gint *pitch1, gint *angle1, gint *pitch2, gint *angle2)
 get the filltype data from selected objects
static void fill_type_dialog_set_values (struct fill_type_data *fill_type_data, OBJECT_FILLING type, gint width, gint pitch1, gint angle1, gint pitch2, gint angle2)
 set the filltype in the filltype dialog
void fill_type_dialog_response (GtkWidget *widget, gint response, struct fill_type_data *fill_type_data)
 response function for the filltype dialog
void fill_type_dialog (GSCHEM_TOPLEVEL *w_current)
 Creates the fill type dialog.
void arc_angle_dialog_response (GtkWidget *w, gint response, GSCHEM_TOPLEVEL *w_current)
 response function for the arc angle dialog
void arc_angle_dialog (GSCHEM_TOPLEVEL *w_current, OBJECT *arc_object)
 Creates the arc angle dialog.
void translate_dialog_response (GtkWidget *widget, gint response, GSCHEM_TOPLEVEL *w_current)
 response function for the translate dialog
void translate_dialog (GSCHEM_TOPLEVEL *w_current)
 Create the translate dialog.
void text_size_dialog_response (GtkWidget *w, gint response, GSCHEM_TOPLEVEL *w_current)
 response function for the text size dialog
void text_size_dialog (GSCHEM_TOPLEVEL *w_current)
 Create the text size dialog.
void snap_size_dialog_response (GtkWidget *w, gint response, GSCHEM_TOPLEVEL *w_current)
 response function for the snap size dialog
void snap_size_dialog (GSCHEM_TOPLEVEL *w_current)
 Create the snap size dialog.
void slot_edit_dialog_response (GtkWidget *widget, gint response, GSCHEM_TOPLEVEL *w_current)
 response function for the slot edit dialog
void slot_edit_dialog (GSCHEM_TOPLEVEL *w_current, const char *string)
 Create the slot entry dialog.
void about_dialog (GSCHEM_TOPLEVEL *w_current)
 Create the about dialog and show it.
void coord_dialog_response (GtkWidget *w, gint response, GSCHEM_TOPLEVEL *w_current)
 Response function for the coord dialog.
void coord_display_update (GSCHEM_TOPLEVEL *w_current, int x, int y)
 Update the coordinates in the coord dialog box.
void coord_dialog (GSCHEM_TOPLEVEL *w_current, int x, int y)
 Create the coord dialog.
char * index2functionstring (int index)
static void color_menu_swatch_layout_data (GtkCellLayout *layout, GtkCellRenderer *cell, GtkTreeModel *model, GtkTreeIter *iter, gpointer data)
 Cell layout data function for color combobox.
static void color_menu_change_selection (GtkWidget *widget, gpointer data)
 Handle color combobox selection change event.
void color_edit_dialog_apply (GtkWidget *w, GSCHEM_TOPLEVEL *w_current)
 Apply a color change to selected objects.
void color_edit_dialog_response (GtkWidget *widget, gint response, GSCHEM_TOPLEVEL *w_current)
 response function for the color edit dialog
void color_edit_dialog (GSCHEM_TOPLEVEL *w_current)
 Create the color edit dialog.
void x_dialog_hotkeys_response (GtkWidget *w, gint response, GSCHEM_TOPLEVEL *w_current)
 Response function for the hotkey dialog.
void x_dialog_hotkeys (GSCHEM_TOPLEVEL *w_current)
 Creates the hotkeys dialog.
void x_dialog_raise_all (GSCHEM_TOPLEVEL *w_current)
void generic_msg_dialog (const char *msg)
int generic_confirm_dialog (const char *msg)
char * generic_filesel_dialog (const char *msg, const char *templ, gint flags)
void find_text_dialog_response (GtkWidget *w, gint response, GSCHEM_TOPLEVEL *w_current)
 response function for the find text dialog
void find_text_dialog (GSCHEM_TOPLEVEL *w_current)
 Create the text find dialog.
void hide_text_dialog_response (GtkWidget *w, gint response, GSCHEM_TOPLEVEL *w_current)
 Response function for the hide text dialog.
void hide_text_dialog (GSCHEM_TOPLEVEL *w_current)
 Creates the hide text dialog.
void show_text_dialog_response (GtkWidget *widget, gint response, GSCHEM_TOPLEVEL *w_current)
 Response function for the show text dialog.
void show_text_dialog (GSCHEM_TOPLEVEL *w_current)
 Create the show text dialog.
void select_all_text_in_textview (GtkTextView *textview)
 Selects all text in a TextView widget.
int text_view_calculate_real_tab_width (GtkTextView *textview, int tab_size)
void major_changed_dialog (GSCHEM_TOPLEVEL *w_current)
static void close_confirmation_dialog_class_init (CloseConfirmationDialogClass *klass)
static void close_confirmation_dialog_init (CloseConfirmationDialog *self)
static void close_confirmation_dialog_set_property (GObject *object, guint property_id, const GValue *value, GParamSpec *pspec)
static void close_confirmation_dialog_get_property (GObject *object, guint property_id, GValue *value, GParamSpec *pspec)
static GObject * close_confirmation_dialog_constructor (GType type, guint n_construct_properties, GObjectConstructParam *construct_params)
GList * close_confirmation_dialog_get_selected_pages (CloseConfirmationDialog *dialog)
 Returns a list of the selected pages with changes to save.
GType close_confirmation_dialog_get_type ()
static gint count_pages (GtkTreeModel *model)
 Returns the number of pages in the model.
static gchar * get_page_name (GtkTreeModel *model, GtkTreeIter *piter)
 Returns the name to use for the given page in the model.
static void close_confirmation_dialog_set_page_name (GtkTreeViewColumn *tree_column, GtkCellRenderer *cell, GtkTreeModel *tree_model, GtkTreeIter *iter, gpointer data)
 Sets the contents of the name cell in the treeview of dialog.
static void close_confirmation_dialog_callback_renderer_toggled (GtkCellRendererToggle *cell_renderer, gchar *path, gpointer user_data)
 Callback function for the toggled signal of check box in treeview.
static GtkWidget * close_confirmation_dialog_build_page_list (CloseConfirmationDialog *dialog)
 Adds a treeview to confirmation dialog for selecting of pages.
static gboolean get_selected_pages (GtkTreeModel *model, GtkTreePath *path, GtkTreeIter *iter, gpointer data)
 Helps building a list of selected page to save.
void x_dialog_close_changed_page (GSCHEM_TOPLEVEL *w_current, PAGE *page)
 Asks for confirmation before closing a changed page.
gboolean x_dialog_close_window (GSCHEM_TOPLEVEL *w_current)
 Asks for confirmation before closing a window.
int x_dialog_validate_attribute (GtkWindow *parent, char *attribute)
 Validate the input attribute.
void x_dialog_edit_pin_type (GSCHEM_TOPLEVEL *w_current, const GList *obj_list)
 Edit the type of a pin (bus or net)

Variables

char generic_textstring [256] = "refdes=R"
GtkWidget * stwindow
int start_find
PAGE * remember_page
static gpointer close_confirmation_dialog_parent_class = NULL

Define Documentation

#define GLADE_HOOKUP_OBJECT (   component,
  widget,
  name 
)
Value:
g_object_set_data_full (G_OBJECT (component), name, \
    gtk_widget_ref (widget), (GDestroyNotify) gtk_widget_unref)
Todo:
STILL NEED to clean up line lengths in aa and tr

Definition at line 39 of file x_dialog.c.

#define TYPE_CLOSE_CONFIRMATION_DIALOG   (close_confirmation_dialog_get_type ())

Definition at line 3349 of file x_dialog.c.

#define CLOSE_CONFIRMATION_DIALOG (   obj)    (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_CLOSE_CONFIRMATION_DIALOG, CloseConfirmationDialog))

Definition at line 3350 of file x_dialog.c.

#define CLOSE_CONFIRMATION_DIALOG_CLASS (   klass)    (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_CLOSE_CONFIRMATION_DIALOG, CloseConfirmationDialogClass))

Definition at line 3351 of file x_dialog.c.

#define IS_CLOSE_CONFIRMATION_DIALOG (   obj)    (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_CLOSE_CONFIRMATION_DIALOG))

Definition at line 3352 of file x_dialog.c.

#define IS_CLOSE_CONFIRMATION_DIALOG_CLASS (   klass)    (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_CLOSE_CONFIRMATION_DIALOG))

Definition at line 3353 of file x_dialog.c.

#define CLOSE_CONFIRMATION_DIALOG_GET_CLASS (   obj)    (G_TYPE_INSTANCE_GET_CLASS ((obj),TYPE_CLOSE_CONFIRMATION_DIALOG, CloseConfirmationDialogClass))

Definition at line 3354 of file x_dialog.c.


Typedef Documentation

Definition at line 3357 of file x_dialog.c.

Definition at line 3358 of file x_dialog.c.


Enumeration Type Documentation

anonymous enum
Enumerator:
PROP_UNSAVED_PAGE 
PROP_UNSAVED_PAGES 
PROP_SELECTED_PAGES 

Definition at line 3373 of file x_dialog.c.

anonymous enum
Enumerator:
COLUMN_SAVE 
COLUMN_PAGE 
NUM_COLUMNS 

Definition at line 3379 of file x_dialog.c.


Function Documentation

static GtkWidget * create_menu_linetype ( GSCHEM_TOPLEVEL w_current) [static]
Function Description
This function creates a GtkMenu with the different linetypes.

Definition at line 582 of file x_dialog.c.

static gint line_type_dialog_linetype_change ( GtkWidget *  w,
gpointer  data 
) [static]
Function Description
This Function is called when the user changes the line type selection. It sets the dash space/length entries either active or inactive.

Definition at line 724 of file x_dialog.c.

static void line_type_dialog_ok ( GtkWidget *  w,
gpointer  data 
) [static]
Function Description
The function takes the properties of the dialog and applies them to the selected objects.

Definition at line 771 of file x_dialog.c.

Here is the call graph for this function:

static GtkWidget * create_menu_filltype ( GSCHEM_TOPLEVEL w_current) [static]
Function Description
This function creates a GtkMenu with the different fill types.

Definition at line 1032 of file x_dialog.c.

static gint fill_type_dialog_filltype_change ( GtkWidget *  w,
gpointer  data 
) [static]
Function Description
This function sets the entry activity according to the selected filltype of the filltype dialog.

Definition at line 1197 of file x_dialog.c.

static void fill_type_dialog_ok ( GtkWidget *  w,
gpointer  data 
) [static]
Function Description
This function applies the settings of the filltype dialog to the selected objects

Definition at line 1253 of file x_dialog.c.

Here is the call graph for this function:

void destroy_window ( GtkWidget *  widget,
GtkWidget **  window 
)
Todo:
Finish function documentation!!!
Function Description

Definition at line 79 of file x_dialog.c.

void text_input_dialog_apply ( GtkWidget *  w,
GSCHEM_TOPLEVEL w_current 
)
Function Description
This function applies the text from the text entry dialog.

Definition at line 95 of file x_dialog.c.

Here is the call graph for this function:

void text_input_dialog_response ( GtkWidget *  widget,
gint  response,
GSCHEM_TOPLEVEL w_current 
)
Function Description
Callback function for the text entry dialog.

Definition at line 142 of file x_dialog.c.

Here is the call graph for this function:

void text_input_dialog ( GSCHEM_TOPLEVEL w_current)
Function Description
This function creates or raises the modal text entry dialog

Bug:
FIXME: This doesn't work. Why?

Definition at line 165 of file x_dialog.c.

Here is the call graph for this function:

gint change_alignment ( GtkComboBox *  w,
GSCHEM_TOPLEVEL w_current 
)
Function Description
This function stores a change of the text alignment in the GSCHEM_TOPLEVEL struct.
Todo:
Remove that function. Only the OK-Button should set any properties in the GSCHEM_TOPLEVEL struct.

Definition at line 269 of file x_dialog.c.

static GtkListStore* create_menu_alignment ( GSCHEM_TOPLEVEL w_current) [static]
Function Description
This function creates a GtkListStore with nine different alignment entries.

Definition at line 293 of file x_dialog.c.

static GtkWidget * create_color_menu ( GSCHEM_TOPLEVEL w_current) [static]
Function Description
Creates a #GtkComboBox with the color list and swatches showing each of the available colors.

The backing #GtkTreeModel is a #GtkListStore with two columns, the first holding the user-friendly name of the color, and the other the color map index.

Parameters:
[in]w_currentThe current gschem context.

Definition at line 2421 of file x_dialog.c.

Here is the call graph for this function:

void text_edit_dialog_ok ( GtkWidget *  w,
GSCHEM_TOPLEVEL w_current 
)
Function Description
This function applies the user settings to the selected text objects and closes the dialog

Definition at line 341 of file x_dialog.c.

Here is the call graph for this function:

void text_edit_dialog_response ( GtkWidget *  widget,
gint  response,
GSCHEM_TOPLEVEL w_current 
)
Function Description
This function receives the user response of the text property dialog. The response is either OK, Cancel or delete.

Definition at line 389 of file x_dialog.c.

Here is the call graph for this function:

void text_edit_dialog ( GSCHEM_TOPLEVEL w_current,
const char *  string,
int  text_size,
int  text_alignment 
)
Function Description
This Function creates the dialog to edit text properties.
Todo:

Check why there's no color in the calling parameters

If more than one text element is selected, add an unchanged option

Bug:
FIXME: Set tab's width in the textview widget.

Definition at line 415 of file x_dialog.c.

Here is the call graph for this function:

static gboolean selection_get_line_type ( GList *  selection,
OBJECT_END *  end,
OBJECT_TYPE *  type,
gint *  width,
gint *  length,
gint *  space 
) [static]
Function Description
Get linetype information over all selected objects. If a object property is different to the other objects, then return -2 in that variable.
Parameters:
[in]selectionthe selection list
[out]endOBJECT_END type
[out]typeOBJECT_FILLING type
[out]widthline width
[out]lengthlength of each line
[out]spacespace between points and lines
Returns:
TRUE if linetype found, FALSE otherwise

Definition at line 627 of file x_dialog.c.

static void line_type_dialog_set_values ( struct line_type_data line_type_data,
OBJECT_END  end,
OBJECT_TYPE  type,
gint  width,
gint  length,
gint  space 
) [static]
Function Description
Set all widgets in the linetype dialog. Variables marked with the invalid value -2 are set to *unchanged*.
Parameters:
[in]line_type_datadialog structure
[in]endOBJECT_END type (currently not used)
[in]typeOBJECT_FILLING type
[in]widthfill width.
[in]lengthlength of each line
[in]spacespace between points and lines

Definition at line 676 of file x_dialog.c.

void line_type_dialog_response ( GtkWidget *  widget,
gint  response,
struct line_type_data line_type_data 
)
Function Description
This function takes the user input and applies it to selected objects. After that it kills the dialog.

Definition at line 865 of file x_dialog.c.

Here is the call graph for this function:

void line_type_dialog ( GSCHEM_TOPLEVEL w_current)
Function Description
This function creates and sets up a dialog for manipulating the line width and the line type setting of objects.

Definition at line 892 of file x_dialog.c.

Here is the call graph for this function:

static gboolean selection_get_fill_type ( GList *  selection,
OBJECT_FILLING *  type,
gint *  width,
gint *  pitch1,
gint *  angle1,
gint *  pitch2,
gint *  angle2 
) [static]
Function Description
Get filltype information over all selected objects. If a object property is different to the other objects, then return -2 in that variable.
Parameters:
[in]selectionthe selection list
[out]typeOBJECT_FILLING type
[out]widthfill width.
[out]pitch1cross hatch line distance
[out]angle1cross hatch angle
[out]pitch2cross hatch line distance
[out]angle2cross hatch angle
Returns:
TRUE if filltype found, FALSE otherwise

Definition at line 1077 of file x_dialog.c.

static void fill_type_dialog_set_values ( struct fill_type_data fill_type_data,
OBJECT_FILLING  type,
gint  width,
gint  pitch1,
gint  angle1,
gint  pitch2,
gint  angle2 
) [static]
Function Description
Set all widgets in the filltype dialog. Variables marked with the invalid value -2 are set to *unchanged*.
Parameters:
[in]fill_type_datadialog structure
[in]typeOBJECT_FILLING type
[in]widthfill width.
[in]pitch1cross hatch line distance
[in]angle1cross hatch angle
[in]pitch2cross hatch line distance
[in]angle2cross hatch angle

Definition at line 1130 of file x_dialog.c.

void fill_type_dialog_response ( GtkWidget *  widget,
gint  response,
struct fill_type_data fill_type_data 
)
Function Description
This function handles the user response to the filltype dialog. It destroys the dialog after that.

Definition at line 1357 of file x_dialog.c.

Here is the call graph for this function:

void fill_type_dialog ( GSCHEM_TOPLEVEL w_current)
Function Description
This function creates the fill type dialog. It uses the selection to set it's initial values.

Definition at line 1386 of file x_dialog.c.

Here is the call graph for this function:

void arc_angle_dialog_response ( GtkWidget *  w,
gint  response,
GSCHEM_TOPLEVEL w_current 
)
Function Description
The response function of th arc angle dialog takes the content of the dialog and applies it on the current arc. If the dialog is closed or canceled the function destroys the dialog.

Definition at line 1547 of file x_dialog.c.

Here is the call graph for this function:

void arc_angle_dialog ( GSCHEM_TOPLEVEL w_current,
OBJECT *  arc_object 
)
Function Description
This function creates the arc angle dialog. Depending on the arc_object the entries are filled with the arc OBJECT properties or with some standard values.
Parameters:
[in]w_currentThe GSCHEM_TOPLEVEL object
[in]arc_objectan arc OBJECT if used to modify an arc or NULL to create a new arc.

Definition at line 1594 of file x_dialog.c.

Here is the call graph for this function:

void translate_dialog_response ( GtkWidget *  widget,
gint  response,
GSCHEM_TOPLEVEL w_current 
)
Function Description
This function takes the user action and applies it.
Todo:
improve error detection / use a spin button?

Definition at line 1706 of file x_dialog.c.

Here is the call graph for this function:

void translate_dialog ( GSCHEM_TOPLEVEL w_current)
Function Description
Create the dialog to translate symbols.

Definition at line 1739 of file x_dialog.c.

Here is the call graph for this function:

void text_size_dialog_response ( GtkWidget *  w,
gint  response,
GSCHEM_TOPLEVEL w_current 
)
Function Description
This function takes the user input and applies it to gschem

Definition at line 1804 of file x_dialog.c.

Here is the call graph for this function:

void text_size_dialog ( GSCHEM_TOPLEVEL w_current)
Function Description
This function creates the text size dialog.

Definition at line 1838 of file x_dialog.c.

Here is the call graph for this function:

void snap_size_dialog_response ( GtkWidget *  w,
gint  response,
GSCHEM_TOPLEVEL w_current 
)
Function Description
This is the response function for the snap size dialog. It sets the given snap size to gschem.

Definition at line 1908 of file x_dialog.c.

Here is the call graph for this function:

void snap_size_dialog ( GSCHEM_TOPLEVEL w_current)
Function Description
This function creates the snap size dialog.

Definition at line 1944 of file x_dialog.c.

Here is the call graph for this function:

void slot_edit_dialog_response ( GtkWidget *  widget,
gint  response,
GSCHEM_TOPLEVEL w_current 
)
Function Description
The function takes the dialog entry and applies the new slot to the symbol.

Definition at line 2014 of file x_dialog.c.

Here is the call graph for this function:

void slot_edit_dialog ( GSCHEM_TOPLEVEL w_current,
const char *  string 
)
Function Description
This function creates the slot edit dialog.

Definition at line 2051 of file x_dialog.c.

Here is the call graph for this function:

void about_dialog ( GSCHEM_TOPLEVEL w_current)
Function Description
This function creates the about dialog.

Definition at line 2123 of file x_dialog.c.

void coord_dialog_response ( GtkWidget *  w,
gint  response,
GSCHEM_TOPLEVEL w_current 
)
Function Description
This function destroys the coord dialog box and does some cleanup.

Definition at line 2173 of file x_dialog.c.

void coord_display_update ( GSCHEM_TOPLEVEL w_current,
int  x,
int  y 
)
Function Description
This function takes the screen coordinates and prints the screen and the world coordinates in the coord dialog.

Definition at line 2186 of file x_dialog.c.

Here is the call graph for this function:

void coord_dialog ( GSCHEM_TOPLEVEL w_current,
int  x,
int  y 
)
Function Description
This function creates the coord dialog box.

Definition at line 2208 of file x_dialog.c.

Here is the call graph for this function:

char* index2functionstring ( int  index)
Todo:
Finish function documentation!!!
Function Description
Warning:
Caller must g_free returned character string.

Definition at line 2277 of file x_dialog.c.

static void color_menu_swatch_layout_data ( GtkCellLayout *  layout,
GtkCellRenderer *  cell,
GtkTreeModel *  model,
GtkTreeIter *  iter,
gpointer  data 
) [static]
Function Description
Cell layout data function to support color swatches in the color combobox.
Parameters:
layout
cell
model
iter
datathe current GSCHEM_TOPLEVEL pointer.

Definition at line 2361 of file x_dialog.c.

Here is the call graph for this function:

static void color_menu_change_selection ( GtkWidget *  widget,
gpointer  data 
) [static]
Function Description
Update application state to reflect color combobox selection changes.
Parameters:
widget
datathe current GSCHEM_TOPLEVEL pointer.

Definition at line 2388 of file x_dialog.c.

void color_edit_dialog_apply ( GtkWidget *  w,
GSCHEM_TOPLEVEL w_current 
)
Function Description
This function applies a color change to the currently selected objects.

Definition at line 2483 of file x_dialog.c.

Here is the call graph for this function:

void color_edit_dialog_response ( GtkWidget *  widget,
gint  response,
GSCHEM_TOPLEVEL w_current 
)
Function Description
This function takes the user response from the color edit dialog

Definition at line 2510 of file x_dialog.c.

Here is the call graph for this function:

void color_edit_dialog ( GSCHEM_TOPLEVEL w_current)
Function Description
This function creates the color edit dialog

Definition at line 2531 of file x_dialog.c.

Here is the call graph for this function:

void x_dialog_hotkeys_response ( GtkWidget *  w,
gint  response,
GSCHEM_TOPLEVEL w_current 
)
Function Description
This function destroys the hotkey dialog and does some cleanup.

Definition at line 2592 of file x_dialog.c.

void x_dialog_hotkeys ( GSCHEM_TOPLEVEL w_current)
Function Description
This function creates the hotkey dialog and puts the list of hotkeys into it.

Definition at line 2613 of file x_dialog.c.

Here is the call graph for this function:

void x_dialog_raise_all ( GSCHEM_TOPLEVEL w_current)
Todo:
Finish function documentation!!!
Function Description

Definition at line 2695 of file x_dialog.c.

void generic_msg_dialog ( const char *  msg)
Todo:
Finish function documentation!!!
Function Description

Definition at line 2751 of file x_dialog.c.

int generic_confirm_dialog ( const char *  msg)
Todo:
Finish function documentation!!!
Function Description

Definition at line 2776 of file x_dialog.c.

char* generic_filesel_dialog ( const char *  msg,
const char *  templ,
gint  flags 
)
Todo:
Finish function documentation!!!
Function Description
Warning:
Caller must g_free returned character string.

Bug:
FIXME if (folder && path) { dup_string (path, folder); g_free (folder); }

Definition at line 2807 of file x_dialog.c.

void find_text_dialog_response ( GtkWidget *  w,
gint  response,
GSCHEM_TOPLEVEL w_current 
)
Function Description
This function takes the string the user likes to find and searches it in the schematic.

Definition at line 2908 of file x_dialog.c.

Here is the call graph for this function:

void find_text_dialog ( GSCHEM_TOPLEVEL w_current)
Function Description
This function creates the text find dialog.

Definition at line 2957 of file x_dialog.c.

Here is the call graph for this function:

void hide_text_dialog_response ( GtkWidget *  w,
gint  response,
GSCHEM_TOPLEVEL w_current 
)
Function Description
This is the response function of the hide text dialog. It takes the user input and hides all text elements that starts with the searchtext.

Definition at line 3046 of file x_dialog.c.

Here is the call graph for this function:

void hide_text_dialog ( GSCHEM_TOPLEVEL w_current)
Function Description
This function creates the hide text dialog.

Definition at line 3077 of file x_dialog.c.

Here is the call graph for this function:

void show_text_dialog_response ( GtkWidget *  widget,
gint  response,
GSCHEM_TOPLEVEL w_current 
)
Function Description
This function takes the users input and searches all strings starting with the given search text and hides those text objects.

Definition at line 3147 of file x_dialog.c.

Here is the call graph for this function:

void show_text_dialog ( GSCHEM_TOPLEVEL w_current)
Function Description
This function creates the show text dialog.

Definition at line 3178 of file x_dialog.c.

Here is the call graph for this function:

void select_all_text_in_textview ( GtkTextView *  textview)
Function Description
The function selects all the text in a TextView widget.

Definition at line 3247 of file x_dialog.c.

int text_view_calculate_real_tab_width ( GtkTextView *  textview,
int  tab_size 
)
Todo:
Finish function documentation!!!
Function Description

Definition at line 3262 of file x_dialog.c.

void major_changed_dialog ( GSCHEM_TOPLEVEL w_current)
Todo:
Finish function documentation!!!
Function Description

Definition at line 3297 of file x_dialog.c.

static void close_confirmation_dialog_class_init ( CloseConfirmationDialogClass klass) [static]

Definition at line 3435 of file x_dialog.c.

Here is the call graph for this function:

static void close_confirmation_dialog_init ( CloseConfirmationDialog self) [static]

Definition at line 3467 of file x_dialog.c.

static void close_confirmation_dialog_set_property ( GObject *  object,
guint  property_id,
const GValue *  value,
GParamSpec *  pspec 
) [static]

Definition at line 3849 of file x_dialog.c.

static void close_confirmation_dialog_get_property ( GObject *  object,
guint  property_id,
GValue *  value,
GParamSpec *  pspec 
) [static]

Definition at line 3897 of file x_dialog.c.

Here is the call graph for this function:

static GObject * close_confirmation_dialog_constructor ( GType  type,
guint  n_construct_properties,
GObjectConstructParam *  construct_params 
) [static]

Definition at line 3685 of file x_dialog.c.

Here is the call graph for this function:

GList * close_confirmation_dialog_get_selected_pages ( CloseConfirmationDialog dialog)
Function Description
This function returns the pages that the user has selected in the confirmation dialog.

The returned list must be freed.

Parameters:
[in]dialogThe dialog.
Returns:
A GList of selected PAGE* in dialog.

Definition at line 3964 of file x_dialog.c.

Here is the call graph for this function:

GType close_confirmation_dialog_get_type ( )

Definition at line 3408 of file x_dialog.c.

Here is the call graph for this function:

static gint count_pages ( GtkTreeModel *  model) [static]
Function Description
This function determines the number of pages with unsaved changes from the model.
Parameters:
[in]modelThe tree model.
Returns:
The number of pages with unsaved changes.

Definition at line 3485 of file x_dialog.c.

static gchar* get_page_name ( GtkTreeModel *  model,
GtkTreeIter *  piter 
) [static]
Function Description
This function determines the text to be used to identify a specific page from the model of pages with unsaved changes.

If piter is NULL, the name for the first page of the model is returned. Otherwise, it returns the name for the page defined by the pointed iterator.

The returned value must be freed by caller.

Parameters:
[in]modelThe tree model.
[in]piterA pointer on a GtkTreeIter of model or NULL.
Returns:
The name for the page.

Definition at line 3514 of file x_dialog.c.

static void close_confirmation_dialog_set_page_name ( GtkTreeViewColumn *  tree_column,
GtkCellRenderer *  cell,
GtkTreeModel *  tree_model,
GtkTreeIter *  iter,
gpointer  data 
) [static]
Function Description
This functions sets the cell of the treeview with the short name of the page obtained with get_page_name().
Parameters:
[in]tree_columnA GtkTreeColumn.
[in]cellThe GtkCellRenderer that is being rendered by tree_column.
[in]tree_modelThe GtkTreeModel being rendered.
[in]iterA GtkTreeIter of the current row rendered.
[in]data.

Definition at line 3547 of file x_dialog.c.

Here is the call graph for this function:

static void close_confirmation_dialog_callback_renderer_toggled ( GtkCellRendererToggle *  cell_renderer,
gchar *  path,
gpointer  user_data 
) [static]
Function Description
This functions changes the value of the save column in the model for the affected row when user toggles the check box in the treeview.
Parameters:
[in]cell_rendererThe GtkCellRendererToggle.
[in]pathThe GtkTreePath to the concerned row in model.
[in]user_dataThe dialog as user data.

Definition at line 3574 of file x_dialog.c.

static GtkWidget* close_confirmation_dialog_build_page_list ( CloseConfirmationDialog dialog) [static]
Function Description
This function adds a treeview and caption to display the content of the dialog model of pages with unsaved changes.

The treeview displays the page names with check boxes.

Parameters:
[in]dialogThe dialog.
Returns:
A pointer on the GtkVBox to add to dialog.

Definition at line 3608 of file x_dialog.c.

Here is the call graph for this function:

static gboolean get_selected_pages ( GtkTreeModel *  model,
GtkTreePath *  path,
GtkTreeIter *  iter,
gpointer  data 
) [static]
Function Description
This is the GtkTreeModelForeachFunc for function close_confirmation_dialog_get_selected_pages().

It builds from the tree model a list of PAGEs for which a save action has been requested. Each selected page is appended to the GList pointed by data

Parameters:
[in]modelThe tree model.
[in]path.
[in]iter.
[in]dataA pointer on a GList* to fill.
Returns:
FALSE to continue walking the tree.

Definition at line 3933 of file x_dialog.c.

void x_dialog_close_changed_page ( GSCHEM_TOPLEVEL w_current,
PAGE *  page 
)
Function Description
This function asks the user to confirm its closing order for page page while it still has unsaved changes.

It displays a message dialog inviting the user to cancel the closing, or to discard the changes or to save the changes to a file.

Parameters:
[in]w_currentThe toplevel environment.
[in]pageThe page to close.

Definition at line 3989 of file x_dialog.c.

Here is the call graph for this function:

gboolean x_dialog_close_window ( GSCHEM_TOPLEVEL w_current)
Function Description
This function asks the user to confirm its closing order for the given window.

The user is given the possibility to save the pages that currently have unsaved changes, if any.

It returns TRUE if the user really accepts the close of the window. Otherwise the user has somehow cancelled and the window must not be closed.

Parameters:
[in]w_currentThe toplevel environment.
Returns:
TRUE if the window can be closed, FALSE otherwise.

Definition at line 4059 of file x_dialog.c.

Here is the call graph for this function:

int x_dialog_validate_attribute ( GtkWindow *  parent,
char *  attribute 
)
Function Description
This function validates the attribute and if it isn't valid pops up an error message box.
Parameters:
parentThe parent window which spawned this dialog box.
attributeThe attribute to be validated.
Returns:
TRUE if the attribute is valid, FALSE otherwise.

Definition at line 4151 of file x_dialog.c.

void x_dialog_edit_pin_type ( GSCHEM_TOPLEVEL w_current,
const GList *  obj_list 
)
Function Description
This function presents an app modal dialog to edit the type of a pin

Definition at line 4177 of file x_dialog.c.

Here is the call graph for this function:


Variable Documentation

char generic_textstring[256] = "refdes=R"

Definition at line 87 of file x_dialog.c.

GtkWidget* stwindow

Definition at line 2900 of file x_dialog.c.

Definition at line 2901 of file x_dialog.c.

gpointer close_confirmation_dialog_parent_class = NULL [static]

Definition at line 3386 of file x_dialog.c.

 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines