[med-svn] [aghermann] 60/85: whitespace
andrei zavada
hmmr-guest at alioth.debian.org
Thu Sep 26 23:46:32 UTC 2013
This is an automated email from the git hooks/post-receive script.
hmmr-guest pushed a commit to branch master
in repository aghermann.
commit 3d863fc8567f496b50844231bf71e841f2b342ef
Author: Andrei Zavada <johnhommer at gmail.com>
Date: Sat Sep 21 02:34:25 2013 +0300
whitespace
---
upstream/src/aghermann/ui/mw/loadsave.cc | 86 +++++++++++++++---------------
upstream/src/common/lang.hh | 14 ++---
upstream/src/tools/edfhed-gtk.cc | 73 +++++++++++++------------
3 files changed, 88 insertions(+), 85 deletions(-)
diff --git a/upstream/src/aghermann/ui/mw/loadsave.cc b/upstream/src/aghermann/ui/mw/loadsave.cc
index f681c02..44e0982 100644
--- a/upstream/src/aghermann/ui/mw/loadsave.cc
+++ b/upstream/src/aghermann/ui/mw/loadsave.cc
@@ -29,50 +29,50 @@ saving_colors()
return move(
forward_list<pair<const char*, SExpDesignUI::TColour>>
({
- {"MWNight", SExpDesignUI::TColour::mw_night },
- {"MWDay", SExpDesignUI::TColour::mw_day },
- {"MWTicks", SExpDesignUI::TColour::mw_ticks },
- {"MWLabels", SExpDesignUI::TColour::mw_labels },
- {"MWProfile", SExpDesignUI::TColour::mw_profile },
-
- {"ScoreNONE", SExpDesignUI::TColour::score_none },
- {"ScorNeREM1", SExpDesignUI::TColour::score_nrem1 },
- {"ScoreNREM2", SExpDesignUI::TColour::score_nrem2 },
- {"ScoreNREM3", SExpDesignUI::TColour::score_nrem3 },
- {"ScoreNREM4", SExpDesignUI::TColour::score_nrem4 },
- {"ScoreREM", SExpDesignUI::TColour::score_rem },
- {"ScoreWake", SExpDesignUI::TColour::score_wake },
-
- {"SFProfilePSD", SExpDesignUI::TColour::sf_profile_psd},
- {"SFProfileSWU", SExpDesignUI::TColour::sf_profile_swu},
- {"SFProfileMC", SExpDesignUI::TColour::sf_profile_mc },
-
- {"SFPhasicSpindle", SExpDesignUI::TColour::sf_phasic_spindle},
- {"SFPhasicKComplex", SExpDesignUI::TColour::sf_phasic_Kcomplex},
- {"SFPhasicEyeBlink", SExpDesignUI::TColour::sf_phasic_eyeblink},
-
- {"SFEMG", SExpDesignUI::TColour::sf_emg },
- {"SFHypnogram", SExpDesignUI::TColour::sf_hypnogram },
- {"SFArtifacts", SExpDesignUI::TColour::sf_artifact },
- {"SFAnnotations", SExpDesignUI::TColour::sf_annotations},
+ {"MWNight", SExpDesignUI::TColour::mw_night},
+ {"MWDay", SExpDesignUI::TColour::mw_day},
+ {"MWTicks", SExpDesignUI::TColour::mw_ticks},
+ {"MWLabels", SExpDesignUI::TColour::mw_labels},
+ {"MWProfile", SExpDesignUI::TColour::mw_profile},
+
+ {"ScoreNONE", SExpDesignUI::TColour::score_none},
+ {"ScorNeREM1", SExpDesignUI::TColour::score_nrem1},
+ {"ScoreNREM2", SExpDesignUI::TColour::score_nrem2},
+ {"ScoreNREM3", SExpDesignUI::TColour::score_nrem3},
+ {"ScoreNREM4", SExpDesignUI::TColour::score_nrem4},
+ {"ScoreREM", SExpDesignUI::TColour::score_rem},
+ {"ScoreWake", SExpDesignUI::TColour::score_wake},
+
+ {"SFProfilePSD", SExpDesignUI::TColour::sf_profile_psd},
+ {"SFProfileSWU", SExpDesignUI::TColour::sf_profile_swu},
+ {"SFProfileMC", SExpDesignUI::TColour::sf_profile_mc},
+
+ {"SFPhasicSpindle", SExpDesignUI::TColour::sf_phasic_spindle},
+ {"SFPhasicKComplex", SExpDesignUI::TColour::sf_phasic_Kcomplex},
+ {"SFPhasicEyeBlink", SExpDesignUI::TColour::sf_phasic_eyeblink},
+
+ {"SFEMG", SExpDesignUI::TColour::sf_emg},
+ {"SFHypnogram", SExpDesignUI::TColour::sf_hypnogram},
+ {"SFArtifacts", SExpDesignUI::TColour::sf_artifact},
+ {"SFAnnotations", SExpDesignUI::TColour::sf_annotations},
{"SFEmbeddedAnnotations", SExpDesignUI::TColour::sf_embedded_annotations},
- {"SFSelection", SExpDesignUI::TColour::sf_selection },
- {"SFTicks", SExpDesignUI::TColour::sf_ticks },
- {"SFLabels", SExpDesignUI::TColour::sf_labels },
- {"SFCursor", SExpDesignUI::TColour::sf_cursor },
-
- {"BandDelta", SExpDesignUI::TColour::band_delta },
- {"BandTheta", SExpDesignUI::TColour::band_theta },
- {"BandAlpha", SExpDesignUI::TColour::band_alpha },
- {"BandBeta", SExpDesignUI::TColour::band_beta },
- {"BandGamma", SExpDesignUI::TColour::band_gamma },
-
- {"MFSWA", SExpDesignUI::TColour::mf_swa },
- {"MFSWASim", SExpDesignUI::TColour::mf_swa_sim },
- {"MFProcessS", SExpDesignUI::TColour::mf_process_s },
- {"MFPaper", SExpDesignUI::TColour::mf_paper },
- {"MFTicks", SExpDesignUI::TColour::mf_ticks },
- {"MFLabels", SExpDesignUI::TColour::mf_labels }
+ {"SFSelection", SExpDesignUI::TColour::sf_selection},
+ {"SFTicks", SExpDesignUI::TColour::sf_ticks},
+ {"SFLabels", SExpDesignUI::TColour::sf_labels},
+ {"SFCursor", SExpDesignUI::TColour::sf_cursor},
+
+ {"BandDelta", SExpDesignUI::TColour::band_delta},
+ {"BandTheta", SExpDesignUI::TColour::band_theta},
+ {"BandAlpha", SExpDesignUI::TColour::band_alpha},
+ {"BandBeta", SExpDesignUI::TColour::band_beta},
+ {"BandGamma", SExpDesignUI::TColour::band_gamma},
+
+ {"MFSWA", SExpDesignUI::TColour::mf_swa},
+ {"MFSWASim", SExpDesignUI::TColour::mf_swa_sim},
+ {"MFProcessS", SExpDesignUI::TColour::mf_process_s},
+ {"MFPaper", SExpDesignUI::TColour::mf_paper},
+ {"MFTicks", SExpDesignUI::TColour::mf_ticks},
+ {"MFLabels", SExpDesignUI::TColour::mf_labels}
}));
}
} // namespace
diff --git a/upstream/src/common/lang.hh b/upstream/src/common/lang.hh
index 404ed3b..ad71d85 100644
--- a/upstream/src/common/lang.hh
+++ b/upstream/src/common/lang.hh
@@ -9,8 +9,8 @@
* License: GPL
*/
-#ifndef _AGH_COMMON_LANG_H
-#define _AGH_COMMON_LANG_H
+#ifndef AGH_COMMON_LANG_H_
+#define AGH_COMMON_LANG_H_
#if HAVE_CONFIG_H && !defined(VERSION)
# include "config.h"
@@ -29,13 +29,13 @@ typedef unsigned long hash_t;
// g++ bits
-#define MAKE_UNIQUE_CHARP(p) \
+#define MAKE_UNIQUE_CHARP(p) \
unique_ptr<void,void(*)(void*)> p##_pp(p,free);
-#define DELETE_DEFAULT_METHODS(T) \
- T () = delete; \
- T (const T&) = delete; \
+#define DELETE_DEFAULT_METHODS(T) \
+ T () = delete; \
+ T (const T&) = delete; \
void operator=( const T&) = delete;
@@ -53,7 +53,7 @@ typedef unsigned long hash_t;
// # define __unused __attribute__ ((unused))
// # define __packed __attribute__ ((packed))
#define likely(x) __builtin_expect (!!(x), 1)
-#define unlikely(x) __builtin_expect (!!(x), 0)
+#define unlikely(x) __builtin_expect (!!(x), 0)
#define FABUF printf( __FILE__ ":%d (%s): %s\n", __LINE__, __FUNCTION__, __buf__);
diff --git a/upstream/src/tools/edfhed-gtk.cc b/upstream/src/tools/edfhed-gtk.cc
index 492a577..ddf52e4 100644
--- a/upstream/src/tools/edfhed-gtk.cc
+++ b/upstream/src/tools/edfhed-gtk.cc
@@ -91,7 +91,7 @@ sigfile::CEDFFile *Fp;
struct SChannelTmp {
- string Label, PhysicalDim,
+ string Label, PhysicalDim,
PhysicalMin, PhysicalMax,
DigitalMin, DigitalMax,
TransducerType, FilteringInfo,
@@ -129,7 +129,7 @@ size_t channel_no;
int
main( int argc, char **argv)
{
- int c;
+ int c;
while ( (c = getopt( argc, argv, "h")) != -1 )
switch ( c ) {
case 'h':
@@ -174,9 +174,10 @@ main( int argc, char **argv)
}
try {
- auto F = sigfile::CEDFFile (fname,
- sigfile::CSource::no_ancillary_files |
- sigfile::CEDFFile::no_field_consistency_check);
+ auto F = sigfile::CEDFFile (
+ fname,
+ sigfile::CSource::no_ancillary_files |
+ sigfile::CEDFFile::no_field_consistency_check);
channel_no = 0;
Fp = &F;
@@ -240,16 +241,17 @@ widgets_to_edf_data( sigfile::CEDFFile& F)
auto H = channels_tmp.begin();
for ( auto& h : F.channels ) {
- memcpy( h.header.label, agh::str::pad( H->Label, 16).c_str(), 16);
- memcpy( h.header.physical_dim, agh::str::pad( H->PhysicalDim, 8).c_str(), 8);
- memcpy( h.header.physical_min, agh::str::pad( H->PhysicalMin, 8).c_str(), 8);
- memcpy( h.header.physical_max, agh::str::pad( H->PhysicalMax, 8).c_str(), 8);
- memcpy( h.header.digital_min, agh::str::pad( H->DigitalMin, 8).c_str(), 8);
- memcpy( h.header.digital_max, agh::str::pad( H->DigitalMax, 8).c_str(), 8);
- memcpy( h.header.transducer_type, agh::str::pad( H->TransducerType, 80).c_str(), 80);
- memcpy( h.header.filtering_info, agh::str::pad( H->FilteringInfo, 80).c_str(), 80);
- memcpy( h.header.samples_per_record, agh::str::pad( H->SamplesPerRecord, 8).c_str(), 8);
- memcpy( h.header.reserved, agh::str::pad( H->Reserved, 32).c_str(), 32);
+ using agh::str::pad;
+ memcpy( h.header.label, pad( H->Label, 16).c_str(), 16);
+ memcpy( h.header.physical_dim, pad( H->PhysicalDim, 8).c_str(), 8);
+ memcpy( h.header.physical_min, pad( H->PhysicalMin, 8).c_str(), 8);
+ memcpy( h.header.physical_max, pad( H->PhysicalMax, 8).c_str(), 8);
+ memcpy( h.header.digital_min, pad( H->DigitalMin, 8).c_str(), 8);
+ memcpy( h.header.digital_max, pad( H->DigitalMax, 8).c_str(), 8);
+ memcpy( h.header.transducer_type, pad( H->TransducerType, 80).c_str(), 80);
+ memcpy( h.header.filtering_info, pad( H->FilteringInfo, 80).c_str(), 80);
+ memcpy( h.header.samples_per_record, pad( H->SamplesPerRecord, 8).c_str(), 8);
+ memcpy( h.header.reserved, pad( H->Reserved, 32).c_str(), 32);
++H;
}
}
@@ -273,31 +275,32 @@ current_channel_data_to_widgets()
}
gtk_label_set_markup( lChannelsNum, tmp->str);
g_string_free( tmp, TRUE);
- gtk_entry_set_text( e[ChannelLabel], agh::str::trim( HTmpi->Label ) . c_str());
- gtk_entry_set_text( e[ChannelPhysicalDim], agh::str::trim( HTmpi->PhysicalDim) . c_str());
- gtk_entry_set_text( e[ChannelPhysicalMin], agh::str::trim( HTmpi->PhysicalMin) . c_str());
- gtk_entry_set_text( e[ChannelPhysicalMax], agh::str::trim( HTmpi->PhysicalMax) . c_str());
- gtk_entry_set_text( e[ChannelDigitalMin], agh::str::trim( HTmpi->DigitalMin ) . c_str());
- gtk_entry_set_text( e[ChannelDigitalMax], agh::str::trim( HTmpi->DigitalMax ) . c_str());
- gtk_entry_set_text( e[ChannelTransducerType], agh::str::trim( HTmpi->TransducerType) . c_str());
- gtk_entry_set_text( e[ChannelFilteringInfo], agh::str::trim( HTmpi->FilteringInfo) . c_str());
- gtk_entry_set_text( e[ChannelSamplesPerRecord], agh::str::trim( HTmpi->SamplesPerRecord) . c_str());
- gtk_entry_set_text( e[ChannelReserved], agh::str::trim( HTmpi->Reserved) . c_str());
+ using agh::str::trim;
+ gtk_entry_set_text( e[ChannelLabel], trim( HTmpi->Label ).c_str());
+ gtk_entry_set_text( e[ChannelPhysicalDim], trim( HTmpi->PhysicalDim ).c_str());
+ gtk_entry_set_text( e[ChannelPhysicalMin], trim( HTmpi->PhysicalMin ).c_str());
+ gtk_entry_set_text( e[ChannelPhysicalMax], trim( HTmpi->PhysicalMax ).c_str());
+ gtk_entry_set_text( e[ChannelDigitalMin], trim( HTmpi->DigitalMin ).c_str());
+ gtk_entry_set_text( e[ChannelDigitalMax], trim( HTmpi->DigitalMax ).c_str());
+ gtk_entry_set_text( e[ChannelTransducerType], trim( HTmpi->TransducerType ).c_str());
+ gtk_entry_set_text( e[ChannelFilteringInfo], trim( HTmpi->FilteringInfo ).c_str());
+ gtk_entry_set_text( e[ChannelSamplesPerRecord], trim( HTmpi->SamplesPerRecord).c_str());
+ gtk_entry_set_text( e[ChannelReserved], trim( HTmpi->Reserved ).c_str());
}
static void
widgets_to_current_channel_data()
{
- HTmpi->Label = gtk_entry_get_text( e[ChannelLabel]);
- HTmpi->PhysicalDim = gtk_entry_get_text( e[ChannelPhysicalDim]);
- HTmpi->PhysicalMin = gtk_entry_get_text( e[ChannelPhysicalMin]);
- HTmpi->PhysicalMax = gtk_entry_get_text( e[ChannelPhysicalMax]);
- HTmpi->DigitalMin = gtk_entry_get_text( e[ChannelDigitalMin]);
- HTmpi->DigitalMax = gtk_entry_get_text( e[ChannelDigitalMax]);
- HTmpi->TransducerType = gtk_entry_get_text( e[ChannelTransducerType]);
- HTmpi->FilteringInfo = gtk_entry_get_text( e[ChannelFilteringInfo]);
- HTmpi->SamplesPerRecord = gtk_entry_get_text( e[ChannelSamplesPerRecord]);
- HTmpi->Reserved = gtk_entry_get_text( e[ChannelReserved]);
+ HTmpi->Label = gtk_entry_get_text( e[ChannelLabel]);
+ HTmpi->PhysicalDim = gtk_entry_get_text( e[ChannelPhysicalDim]);
+ HTmpi->PhysicalMin = gtk_entry_get_text( e[ChannelPhysicalMin]);
+ HTmpi->PhysicalMax = gtk_entry_get_text( e[ChannelPhysicalMax]);
+ HTmpi->DigitalMin = gtk_entry_get_text( e[ChannelDigitalMin]);
+ HTmpi->DigitalMax = gtk_entry_get_text( e[ChannelDigitalMax]);
+ HTmpi->TransducerType = gtk_entry_get_text( e[ChannelTransducerType]);
+ HTmpi->FilteringInfo = gtk_entry_get_text( e[ChannelFilteringInfo]);
+ HTmpi->SamplesPerRecord = gtk_entry_get_text( e[ChannelSamplesPerRecord]);
+ HTmpi->Reserved = gtk_entry_get_text( e[ChannelReserved]);
}
--
Alioth's /git/debian-med/git-commit-notice on /srv/git.debian.org/git/debian-med/aghermann.git
More information about the debian-med-commit
mailing list