[med-svn] [SCM] aghermann branch, master, updated. 4f7a3b774136ffffbaf9b05d90bd568347bc5461
Andrei Zavada
johnhommer at gmail.com
Fri Nov 16 00:50:08 UTC 2012
The following commit has been merged in the master branch:
commit 02c56e126fab4fe33b180aaad312aa041ab6d2ee
Author: Andrei Zavada <johnhommer at gmail.com>
Date: Thu Oct 11 01:38:25 2012 +0300
Montage Defaults dialog skeleton
diff --git a/data/dialogs.glade.in b/data/dialogs.glade.in
index 9c10a30..ee569d5 100644
--- a/data/dialogs.glade.in
+++ b/data/dialogs.glade.in
@@ -1483,6 +1483,287 @@ GPL-2+</property>
<action-widget response="-7">button6</action-widget>
</action-widgets>
</object>
+ <object class="GtkDialog" id="wMontageDefaults">
+ <property name="can_focus">False</property>
+ <property name="border_width">10</property>
+ <property name="window_position">center-on-parent</property>
+ <property name="type_hint">dialog</property>
+ <signal name="close" handler="gtk_widget_hide" swapped="no"/>
+ <signal name="delete-event" handler="gtk_widget_hide_on_delete" swapped="no"/>
+ <signal name="response" handler="gtk_widget_hide" swapped="no"/>
+ <child internal-child="vbox">
+ <object class="GtkBox" id="dialog-vbox12">
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">2</property>
+ <child>
+ <object class="GtkBox" id="box5">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkLabel" id="label4">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="ypad">8</property>
+ <property name="label" translatable="yes"><b><big>Montage defaults</big></b></property>
+ <property name="use_markup">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSeparator" id="separator6">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="padding">6</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkGrid" id="grid4">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="margin_top">5</property>
+ <property name="margin_bottom">5</property>
+ <property name="row_spacing">10</property>
+ <property name="column_spacing">5</property>
+ <child>
+ <object class="GtkLabel" id="label16">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">1</property>
+ <property name="label" translatable="yes">Show c_hannels:</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">0</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkEntry" id="eMontageDefaultsChannelList">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="invisible_char">•</property>
+ <property name="activates_default">True</property>
+ <property name="invisible_char_set">True</property>
+ <property name="caps_lock_warning">False</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">0</property>
+ <property name="width">2</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="eMontageDefaultsShowPSD">
+ <property name="label" translatable="yes">_PSD</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="xalign">0</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">1</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="eMontageDefaultsShowMC">
+ <property name="label" translatable="yes">_uCont</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="xalign">0</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">2</property>
+ <property name="width">2</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="eMontageDefaultsShowEMG">
+ <property name="label" translatable="yes">E_MG</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="xalign">0</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">3</property>
+ <property name="width">2</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label22">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">1</property>
+ <property name="label" translatable="yes">Profiles:</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">1</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="eMontageDefaultsShowPSDSpectrum">
+ <property name="label" translatable="yes">Sp_ectrum</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="xalign">0</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="top_attach">1</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="eMontageDefaultsOverride">
+ <property name="label" translatable="yes">Over_ride</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="use_underline">True</property>
+ <property name="xalign">0</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">4</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label23">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">1</property>
+ <property name="label" translatable="yes">If already exists, </property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">4</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSeparator" id="separator7">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child internal-child="action_area">
+ <object class="GtkButtonBox" id="dialog-action_area12">
+ <property name="can_focus">False</property>
+ <property name="layout_style">end</property>
+ <child>
+ <object class="GtkButton" id="button5">
+ <property name="label">gtk-cancel</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="bSubjectDetailsOK1">
+ <property name="label">gtk-ok</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="has_default">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="pack_type">end</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <action-widgets>
+ <action-widget response="-6">button5</action-widget>
+ <action-widget response="-5">bSubjectDetailsOK1</action-widget>
+ </action-widgets>
+ </object>
<object class="GtkDialog" id="wScanLog">
<property name="width_request">700</property>
<property name="height_request">280</property>
diff --git a/data/main.glade b/data/main.glade
index 01dadaf..d8c935b 100644
--- a/data/main.glade
+++ b/data/main.glade
@@ -688,6 +688,14 @@ rm */*/*/.*.{psd,mc}</property>
<property name="visible">True</property>
<property name="can_focus">False</property>
<child>
+ <object class="GtkMenuItem" id="iMontageSetDefaults">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Set _defaults...</property>
+ <property name="use_underline">True</property>
+ </object>
+ </child>
+ <child>
<object class="GtkMenuItem" id="iMontageResetAll">
<property name="visible">True</property>
<property name="can_focus">False</property>
@@ -6652,6 +6660,18 @@ EEG microcontinuity algorithm. Read more <a href="http://johnhommer.com/acade
<child>
<placeholder/>
</child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
</object>
</child>
<child>
diff --git a/src/ui/expdesign-construct.cc b/src/ui/expdesign-construct.cc
index cd5060e..361e560 100644
--- a/src/ui/expdesign-construct.cc
+++ b/src/ui/expdesign-construct.cc
@@ -88,6 +88,7 @@ SExpDesignUIWidgets ()
!AGH_GBGETOBJ (GtkMenuItem, iExpBasicSADetectUltradianCycles) ||
!AGH_GBGETOBJ (GtkMenuItem, iExpClose) ||
!AGH_GBGETOBJ (GtkMenuItem, iExpQuit) ||
+ !AGH_GBGETOBJ (GtkMenuItem, iMontageSetDefaults) ||
!AGH_GBGETOBJ (GtkMenuItem, iMontageResetAll) ||
!AGH_GBGETOBJ (GtkMenuItem, iMontageNotchNone) ||
!AGH_GBGETOBJ (GtkMenuItem, iMontageNotch50Hz) ||
@@ -121,6 +122,9 @@ SExpDesignUIWidgets ()
(GCallback)iHelpUsage_activate_cb,
this);
+ g_signal_connect( iMontageSetDefaults, "activate",
+ (GCallback)iMontageSetDefaults_activate_cb,
+ this);
g_signal_connect( iMontageResetAll, "activate",
(GCallback)iMontageResetAll_activate_cb,
this);
@@ -718,6 +722,16 @@ SExpDesignUIWidgets ()
!AGH_GBGETOBJ (GtkSpinButton, eBatchSetupRangeSteps) )
throw runtime_error ("Failed to construct widgets");
+ // ------------- wMontageDefaults
+ if ( !AGH_GBGETOBJ (GtkDialog, wMontageDefaults) ||
+ !AGH_GBGETOBJ (GtkEntry, eMontageDefaultsChannelList) ||
+ !AGH_GBGETOBJ (GtkCheckButton, eMontageDefaultsShowPSD) ||
+ !AGH_GBGETOBJ (GtkCheckButton, eMontageDefaultsShowPSDSpectrum) ||
+ !AGH_GBGETOBJ (GtkCheckButton, eMontageDefaultsShowMC) ||
+ !AGH_GBGETOBJ (GtkCheckButton, eMontageDefaultsShowEMG) ||
+ !AGH_GBGETOBJ (GtkCheckButton, eMontageDefaultsOverride) )
+ throw runtime_error ("Failed to construct widgets");
+
pango_font_description_free( font_desc);
}
diff --git a/src/ui/expdesign-widgets.hh b/src/ui/expdesign-widgets.hh
index 9339ee7..daa1c0a 100644
--- a/src/ui/expdesign-widgets.hh
+++ b/src/ui/expdesign-widgets.hh
@@ -91,6 +91,7 @@ struct SExpDesignUIWidgets {
GtkMenuItem
*iExpRefresh, *iExpPurgeComputed, *iExpAnnotations, *iExpClose, *iExpQuit,
*iExpBasicSADetectUltradianCycles,
+ *iMontageSetDefaults,
*iMontageResetAll,
*iMontageNotchNone, *iMontageNotch50Hz, *iMontageNotch60Hz,
*iHelpAbout,
@@ -287,6 +288,19 @@ struct SExpDesignUIWidgets {
*eBatchSetupRangeWidth,
*eBatchSetupRangeInc,
*eBatchSetupRangeSteps;
+
+ // montage defaults
+ GtkDialog
+ *wMontageDefaults;
+ GtkEntry
+ *eMontageDefaultsChannelList;
+ GtkCheckButton
+ *eMontageDefaultsShowPSD,
+ *eMontageDefaultsShowPSDSpectrum,
+ *eMontageDefaultsShowMC,
+ *eMontageDefaultsShowEMG,
+ *eMontageDefaultsOverride;
+
// colours
enum TColour {
night, day,
diff --git a/src/ui/expdesign_cb.cc b/src/ui/expdesign_cb.cc
index 7c40247..5bf2faa 100644
--- a/src/ui/expdesign_cb.cc
+++ b/src/ui/expdesign_cb.cc
@@ -162,6 +162,16 @@ iExpQuit_activate_cb( GtkMenuItem*, gpointer userdata)
void
+iMontageSetDefaults_activate_cb( GtkMenuItem*, gpointer userdata)
+{
+ auto& ED = *(SExpDesignUI*)userdata;
+
+ if ( GTK_RESPONSE_OK ==
+ gtk_dialog_run( ED.wMontageDefaults) )
+ FAFA;
+}
+
+void
iMontageResetAll_activate_cb( GtkMenuItem*, gpointer userdata)
{
auto& ED = *(SExpDesignUI*)userdata;
diff --git a/src/ui/expdesign_cb.hh b/src/ui/expdesign_cb.hh
index 03ef61a..20f274b 100644
--- a/src/ui/expdesign_cb.hh
+++ b/src/ui/expdesign_cb.hh
@@ -30,6 +30,7 @@ void iExpAnnotations_activate_cb( GtkMenuItem*, gpointer);
void iExpBasicSADetectUltradianCycles_activate_cb( GtkMenuItem*, gpointer);
void iExpClose_activate_cb( GtkMenuItem*, gpointer);
void iExpQuit_activate_cb( GtkMenuItem*, gpointer);
+void iMontageSetDefaults_activate_cb( GtkMenuItem*, gpointer);
void iMontageResetAll_activate_cb( GtkMenuItem*, gpointer);
void iMontageNotchNone_activate_cb( GtkMenuItem*, gpointer);
void iMontageNotch50Hz_activate_cb( GtkMenuItem*, gpointer);
--
Sleep experiment manager
More information about the debian-med-commit
mailing list