atomes 1.1.14
atomes: an atomic scale modeling tool box
Loading...
Searching...
No Matches
m_curve.c File Reference

Curve context menu (mouse right click) More...

#include <gtk/gtk.h>
#include <stdlib.h>
#include "global.h"
#include "callbacks.h"
#include "curve.h"
#include "cedit.h"
#include "datab.h"
+ Include dependency graph for m_curve.c:

Go to the source code of this file.

Functions

DataLayoutcurve_default_layout (project *pid, int rid, int cid)
 prepare the default layout for a curve
 
void autoscale (gpointer data)
 autoscale callback
 
CurveExtrainit_extra (tint *id)
 create extra data set
 
void add_extra (ExtraSets *sets, tint *id)
 add set to the extra set(s)
 
void remove_extra (ExtraSets *sets, CurveExtra *ctmp)
 remove data from extra set(s)
 
void curve_window_add_menu_bar (tint *data)
 add menu bar to the curve window
 
void prep_extra_rid (tint *data)
 look up extra data set(s) for curve
 
void action_to_plot (gpointer data)
 add to plot, or, remove curve from plot
 
G_MODULE_EXPORT void curve_edit_menu_action (GSimpleAction *action, GVariant *parameter, gpointer data)
 curve menu edit action callback
 
G_MODULE_EXPORT void curve_add_remove_menu_action (GSimpleAction *action, GVariant *parameter, gpointer data)
 curve menu add / remove action callback
 
G_MODULE_EXPORT void curve_menu_bar_action (GSimpleAction *action, GVariant *parameter, gpointer data)
 curve menu action callback
 
gboolean was_not_added (ExtraSets *sets, int a, int b, int c)
 test if already in the menu or not
 
GMenu * curve_section (GSimpleActionGroup *action_group, gchar *act, ExtraSets *sets, gboolean add, int edit, int a, int b, tint *data)
 create curve submenu
 
GMenu * create_curve_submenu (GSimpleActionGroup *action_group, gchar *act, tint *data, gboolean add, int edit)
 create curve add / remove submenus
 
GIcon * get_gicon_from_data (int format, const gchar *icon)
 
GMenu * create_curve_menu (gchar *str)
 create the curve submenu
 
GMenu * edit_data_section (GSimpleActionGroup *action_group, gchar *str, tint *data)
 create the edit data submenu
 
GMenu * curve_close_section (gchar *str)
 create the close menu item
 
GMenu * create_data_menu (GSimpleActionGroup *action_group, int pop, gchar *str, tint *data)
 create the save data submenu
 
GMenu * curve_menu_bar (project *this_proj, GSimpleActionGroup *action_group, gchar *str, tint *data)
 create the curve window menu bar
 
GMenu * create_add_remove_section (GSimpleActionGroup *action_group, gchar *act, int num, tint *data)
 create the add / remove curve submenus
 
GMenu * autoscale_section (gchar *str)
 create autoscale menu item
 
GtkWidget * curve_popup_menu (gpointer data)
 create curve popup menu
 

Variables

int ** extrarid
 

Detailed Description

Curve context menu (mouse right click)

Author
Sébastien Le Roux sebas.nosp@m.tien.nosp@m..lero.nosp@m.ux@i.nosp@m.pcms..nosp@m.unis.nosp@m.tra.f.nosp@m.r

Definition in file m_curve.c.

Function Documentation

◆ action_to_plot()

void action_to_plot ( gpointer data)

add to plot, or, remove curve from plot

Parameters
datathe associated data pointer

Definition at line 207 of file m_curve.c.

◆ add_extra()

void add_extra ( ExtraSets * sets,
tint * id )

add set to the extra set(s)

Parameters
setsthe extra set(s)
idthe associated data pointer

Definition at line 118 of file m_curve.c.

◆ autoscale()

void autoscale ( gpointer data)

autoscale callback

Parameters
datathe associated data pointer

Definition at line 82 of file m_curve.c.

◆ autoscale_section()

GMenu * autoscale_section ( gchar * str)

create autoscale menu item

Parameters
strthe action string id

Definition at line 648 of file m_curve.c.

◆ create_add_remove_section()

GMenu * create_add_remove_section ( GSimpleActionGroup * action_group,
gchar * act,
int num,
tint * data )

create the add / remove curve submenus

Parameters
action_groupthe menu action group
actthe action string
numthe number of curve(s) to add
datathe associatec data pointer

Definition at line 601 of file m_curve.c.

◆ create_curve_menu()

GMenu * create_curve_menu ( gchar * str)

create the curve submenu

Parameters
strthe action string

Definition at line 467 of file m_curve.c.

◆ create_curve_submenu()

GMenu * create_curve_submenu ( GSimpleActionGroup * action_group,
gchar * act,
tint * data,
gboolean add,
int edit )

create curve add / remove submenus

Parameters
action_groupthe menu action group
actthe action string
datathe associated data pointer
addremove (0) or add (1) menu
editdata edition (1 / 0)

Definition at line 391 of file m_curve.c.

◆ create_data_menu()

GMenu * create_data_menu ( GSimpleActionGroup * action_group,
int pop,
gchar * str,
tint * data )

create the save data submenu

Parameters
action_groupthe menu action group
pop0 = menu bar, 1 = popup menu
strthe action string
datathe associated data pointer

Definition at line 532 of file m_curve.c.

◆ curve_add_remove_menu_action()

G_MODULE_EXPORT void curve_add_remove_menu_action ( GSimpleAction * action,
GVariant * parameter,
gpointer data )

curve menu add / remove action callback

Parameters
actionthe GAction sending the signal
parameterGVariant parameter of the GAction
datathe associated data pointer

Definition at line 265 of file m_curve.c.

◆ curve_close_section()

GMenu * curve_close_section ( gchar * str)

create the close menu item

Parameters
strthe action string

Definition at line 513 of file m_curve.c.

◆ curve_default_layout()

DataLayout * curve_default_layout ( project * pid,
int rid,
int cid )
extern

prepare the default layout for a curve

Parameters
pidthe project id
ridthe analysis id
cidthe curve id

Definition at line 57 of file cwidget.c.

◆ curve_edit_menu_action()

G_MODULE_EXPORT void curve_edit_menu_action ( GSimpleAction * action,
GVariant * parameter,
gpointer data )

curve menu edit action callback

Parameters
actionthe GAction sending the signal
parameterGVariant parameter of the GAction
datathe associated data pointer

Definition at line 251 of file m_curve.c.

◆ curve_menu_bar()

GMenu * curve_menu_bar ( project * this_proj,
GSimpleActionGroup * action_group,
gchar * str,
tint * data )

create the curve window menu bar

Parameters
this_projthe target project
action_groupthe menu action group
strthe action string
datathe associated data pointer

Definition at line 553 of file m_curve.c.

◆ curve_menu_bar_action()

G_MODULE_EXPORT void curve_menu_bar_action ( GSimpleAction * action,
GVariant * parameter,
gpointer data )

curve menu action callback

Parameters
actionthe GAction sending the signal
parameterGVariant parameter of the GAction
datathe associated data pointer

Definition at line 279 of file m_curve.c.

◆ curve_popup_menu()

GtkWidget * curve_popup_menu ( gpointer data)

create curve popup menu

Parameters
datathe associated data pointer

Definition at line 664 of file m_curve.c.

◆ curve_section()

GMenu * curve_section ( GSimpleActionGroup * action_group,
gchar * act,
ExtraSets * sets,
gboolean add,
int edit,
int a,
int b,
tint * data )

create curve submenu

Parameters
action_groupthe menu action group
actthe action string
setsthe target extra sets
addremove (0) or add (1) menu
editdata edition (1 / 0)
atarget project
btarget calculation
datathe associated data pointer

Definition at line 346 of file m_curve.c.

◆ curve_window_add_menu_bar()

void curve_window_add_menu_bar ( tint * data)

add menu bar to the curve window

Parameters
datathe associated data pointer

Definition at line 570 of file m_curve.c.

◆ edit_data_section()

GMenu * edit_data_section ( GSimpleActionGroup * action_group,
gchar * str,
tint * data )

create the edit data submenu

Parameters
action_groupthe menu action group
strthe action string
datathe associated data pointer

Definition at line 488 of file m_curve.c.

◆ get_gicon_from_data()

GIcon * get_gicon_from_data ( int format,
const gchar * icon )
extern

Definition at line 484 of file gui.c.

◆ init_extra()

CurveExtra * init_extra ( tint * id)

create extra data set

Parameters
idthe associated data pointer

Definition at line 97 of file m_curve.c.

◆ prep_extra_rid()

void prep_extra_rid ( tint * data)

look up extra data set(s) for curve

Parameters
datathe associated data pointer

Definition at line 184 of file m_curve.c.

◆ remove_extra()

void remove_extra ( ExtraSets * sets,
CurveExtra * ctmp )

remove data from extra set(s)

Parameters
setsthe extra set(s)
ctmpthe data set to remove from the extra set(s)

Definition at line 142 of file m_curve.c.

◆ was_not_added()

gboolean was_not_added ( ExtraSets * sets,
int a,
int b,
int c )

test if already in the menu or not

Parameters
setsthe target extra sets
athe target project
bthe target calculation
cthe target curve

Definition at line 314 of file m_curve.c.

Variable Documentation

◆ extrarid

int** extrarid

Definition at line 72 of file m_curve.c.