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

Functions to create the periodic table of the elements
Functions to select element from the periodic table. More...

#include "global.h"
+ Include dependency graph for w_periodic.c:

Go to the source code of this file.

Functions

gchar * get_electronic_structure (int r, int c)
 get electronic structure for this (row,column) combination
 
int is_in_table (int i, int j)
 is this (row,column) combination a chemical element ?
 
GtkWidget * create_el_preview (int p, int a, int r, int c)
 create element preview
 
GtkWidget * el_preview (int p, int a)
 create element preview CSS widget
 
G_MODULE_EXPORT gboolean on_element_focus (GtkWidget *widget, GdkEvent *event, gpointer data)
 periodic table focus event callback GTK3
 
G_MODULE_EXPORT void run_periodic_table (GtkDialog *info, gint response_id, gpointer data)
 periodic table - running the dialog
 
G_MODULE_EXPORT void get_element (GtkButton *but, gpointer data)
 get element from periodic table button
 
GtkWidget * create_css_button (int p, int id, int r, int c)
 create CSS periodic table element button
 
GtkWidget * create_css_group (int p, int i)
 create group CSS
 
GtkWidget * css_element (int p, int i, int j)
 create CSS for the periodic table elements
 
GtkWidget * periodic_table (int p, int a)
 create periodic table
 
int get_atom_id_from_periodic_table (atom_search *asearch)
 get atom Z from selection in the periodic table
 

Variables

insertion_menu mol []
 
atom_searchperiodic_search
 
int element
 
dint table_p [118]
 
ColRGBA rtcolo [11]
 
gchar * ptcolo [11] = {"#8EFF8E", "#F5FF53", "#FFB853", "#FF6C7D", "#F4A7FF", "#408538", "#B15EFF", "#8EE3FF", "#505DFD", "#7EFFEB", "#5FC0B0"}
 

Detailed Description

Functions to create the periodic table of the elements
Functions to select element from the periodic table.

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 w_periodic.c.

Function Documentation

◆ create_css_button()

GtkWidget * create_css_button ( int p,
int id,
int r,
int c )

create CSS periodic table element button

Parameters
pthe target project id
idis element table (1 / 0)
rrow
ccolumn

Definition at line 422 of file w_periodic.c.

◆ create_css_group()

GtkWidget * create_css_group ( int p,
int i )

create group CSS

Parameters
pthe target project id
ithe group

Definition at line 576 of file w_periodic.c.

◆ create_el_preview()

GtkWidget * create_el_preview ( int p,
int a,
int r,
int c )

create element preview

Parameters
pthe target project id
atarget atom search id
rrow
ccolumn

Definition at line 233 of file w_periodic.c.

◆ css_element()

GtkWidget * css_element ( int p,
int i,
int j )

create CSS for the periodic table elements

Parameters
ptarget project id
irow
jcolumn

Definition at line 607 of file w_periodic.c.

◆ el_preview()

GtkWidget * el_preview ( int p,
int a )

create element preview CSS widget

Parameters
pthe target project id
atarget atom search id

Definition at line 309 of file w_periodic.c.

◆ get_atom_id_from_periodic_table()

int get_atom_id_from_periodic_table ( atom_search * asearch)

get atom Z from selection in the periodic table

Parameters
asearchtarget atom search, if any

Definition at line 672 of file w_periodic.c.

◆ get_electronic_structure()

gchar * get_electronic_structure ( int r,
int c )

get electronic structure for this (row,column) combination

Parameters
rrow
ccolumn

Definition at line 86 of file w_periodic.c.

◆ get_element()

G_MODULE_EXPORT void get_element ( GtkButton * but,
gpointer data )

get element from periodic table button

Parameters
butthe GtkButton sending the signal
datathe associated data pointer

Definition at line 405 of file w_periodic.c.

◆ is_in_table()

int is_in_table ( int i,
int j )

is this (row,column) combination a chemical element ?

Parameters
irow
jcolumn

Definition at line 194 of file w_periodic.c.

◆ on_element_focus()

G_MODULE_EXPORT gboolean on_element_focus ( GtkWidget * widget,
GdkEvent * event,
gpointer data )

periodic table focus event callback GTK3

Parameters
widgetthe GtkWidget sending the signal
eventthe GdkEvent triggering the signal
datathe associated data pointer

Definition at line 352 of file w_periodic.c.

◆ periodic_table()

GtkWidget * periodic_table ( int p,
int a )

create periodic table

Parameters
ptarget project id
atarget atom search id

Definition at line 632 of file w_periodic.c.

◆ run_periodic_table()

G_MODULE_EXPORT void run_periodic_table ( GtkDialog * info,
gint response_id,
gpointer data )

periodic table - running the dialog

Parameters
infothe GtkDialog sending the signal
response_idthe response id
datathe associated data pointer

Definition at line 392 of file w_periodic.c.

Variable Documentation

◆ element

int element

Definition at line 61 of file w_periodic.c.

◆ mol

insertion_menu mol[]
extern

Definition at line 193 of file w_library.c.

◆ periodic_search

atom_search* periodic_search

Definition at line 60 of file w_periodic.c.

◆ ptcolo

gchar* ptcolo[11] = {"#8EFF8E", "#F5FF53", "#FFB853", "#FF6C7D", "#F4A7FF", "#408538", "#B15EFF", "#8EE3FF", "#505DFD", "#7EFFEB", "#5FC0B0"}

Definition at line 76 of file w_periodic.c.

◆ rtcolo

ColRGBA rtcolo[11]
Initial value:
= {{142, 255, 142, 1.0},
{245, 255, 83, 1.0},
{255, 184, 83, 1.0},
{255, 108, 125, 1.0},
{244, 167, 255, 1.0},
{64, 133, 56},
{177, 94, 255},
{142, 227, 255, 1.0},
{80, 93, 253, 1.0},
{126, 255, 235, 1.0},
{95, 192, 176, 1.0}}

Definition at line 65 of file w_periodic.c.

◆ table_p

dint table_p[118]

Definition at line 63 of file w_periodic.c.