r1018: *** empty log message ***
[ctsim.git] / src / dialogs.cpp
index b4811ed1faeb74aff28170b42c981a63f9df90e4..75596d4c939291e94394a78d6f1bd59a59f796b9 100644 (file)
@@ -9,7 +9,7 @@
 **  This is part of the CTSim program
 **  Copyright (c) 1983-2001 Kevin Rosenberg
 **
 **  This is part of the CTSim program
 **  Copyright (c) 1983-2001 Kevin Rosenberg
 **
-**  $Id: dialogs.cpp,v 1.50 2001/03/11 15:27:30 kevin Exp $
+**  $Id: dialogs.cpp,v 1.55 2001/09/24 09:40:42 kevin Exp $
 **
 **  This program is free software; you can redistribute it and/or modify
 **  it under the terms of the GNU General Public License (version 2) as
 **
 **  This program is free software; you can redistribute it and/or modify
 **  it under the terms of the GNU General Public License (version 2) as
@@ -47,6 +47,7 @@
 #include "docs.h"
 #include "views.h"
 #include "imagefile.h"
 #include "docs.h"
 #include "views.h"
 #include "imagefile.h"
+#include "projections.h"
 
 #if defined(MSVC) || HAVE_SSTREAM
 #include <sstream>
 
 #if defined(MSVC) || HAVE_SSTREAM
 #include <sstream>
@@ -142,6 +143,64 @@ DialogGetPhantom::getPhantom()
 }
 
 
 }
 
 
+///////////////////////////////////////////////////////////////////////
+// CLASS IMPLEMENTATION
+//    DialogGetThetaRange
+///////////////////////////////////////////////////////////////////////
+
+DialogGetThetaRange::DialogGetThetaRange (wxWindow* pParent, int iDefaultThetaRange)
+: wxDialog (pParent, -1, _T("Select Phantom"), wxDefaultPosition, wxDefaultSize, wxDEFAULT_DIALOG_STYLE | wxCAPTION)
+{
+  wxBoxSizer* pTopSizer = new wxBoxSizer (wxVERTICAL);
+  
+  pTopSizer->Add (new wxStaticText (this, -1, "Select Theta Range"), 0, wxCENTER | wxALL, 5);
+  
+  pTopSizer->Add (new wxStaticLine (this, -1, wxDefaultPosition, wxSize(3,3), wxHORIZONTAL), 0, wxEXPAND | wxALL, 5);
+  
+  wxString asTitle[] = {"Unconstrained", "Normalized to 2pi", "Fold to pi"};
+  
+  m_pRadioBoxThetaRange = new wxRadioBox (this, -1, _T("Theta Range"), wxDefaultPosition, wxDefaultSize, 3, asTitle, 1, wxRA_SPECIFY_COLS);
+  if (iDefaultThetaRange == ParallelRaysums::THETA_RANGE_UNCONSTRAINED)
+    m_pRadioBoxThetaRange->SetSelection (0);
+  else if (iDefaultThetaRange == ParallelRaysums::THETA_RANGE_NORMALIZE_TO_TWOPI)
+    m_pRadioBoxThetaRange->SetSelection (1);
+  else if (iDefaultThetaRange == ParallelRaysums::THETA_RANGE_FOLD_TO_PI)
+    m_pRadioBoxThetaRange->SetSelection (2);
+
+  pTopSizer->Add (m_pRadioBoxThetaRange, 0, wxALL | wxALIGN_CENTER);
+  
+  pTopSizer->Add (new wxStaticLine (this, -1, wxDefaultPosition, wxSize(3,3), wxHORIZONTAL), 0, wxEXPAND | wxALL, 5);
+  
+  wxBoxSizer* pButtonSizer = new wxBoxSizer (wxHORIZONTAL);
+  wxButton* pButtonOk = new wxButton (this, wxID_OK, "Okay");
+  pButtonSizer->Add (pButtonOk, 0, wxEXPAND | wxALL, 10);
+  wxButton* pButtonCancel = new wxButton (this, wxID_CANCEL, "Cancel");
+  pButtonSizer->Add (pButtonCancel, 0, wxEXPAND | wxALL, 10);
+  CTSimHelpButton* pButtonHelp = new CTSimHelpButton (this, IDH_DLG_THETA_RANGE);
+  pButtonSizer->Add (pButtonHelp, 0, wxEXPAND | wxALL, 10);
+
+  pTopSizer->Add (pButtonSizer, 0, wxALIGN_CENTER);
+  pButtonOk->SetDefault();
+  
+  SetAutoLayout (true);
+  SetSizer (pTopSizer);
+  pTopSizer->Fit (this);
+  pTopSizer->SetSizeHints (this);
+}
+
+int
+DialogGetThetaRange::getThetaRange()
+{
+  int iSelection = m_pRadioBoxThetaRange->GetSelection();
+  if (iSelection == 0)
+    return ParallelRaysums::THETA_RANGE_UNCONSTRAINED;
+  else if (iSelection == 1)
+    return ParallelRaysums::THETA_RANGE_NORMALIZE_TO_TWOPI;
+  else
+    return ParallelRaysums::THETA_RANGE_FOLD_TO_PI;
+}
+
+
 ///////////////////////////////////////////////////////////////////////
 // CLASS IMPLEMENTATION
 //    DialogGetComparisonImage
 ///////////////////////////////////////////////////////////////////////
 // CLASS IMPLEMENTATION
 //    DialogGetComparisonImage
@@ -392,7 +451,7 @@ DialogAutoScaleParameters::DialogAutoScaleParameters (wxWindow *pParent, double
   
   pTopSizer->Add (new wxStaticLine (this, -1, wxDefaultPosition, wxSize(3,3), wxHORIZONTAL), 0, wxEXPAND | wxALL, 5);
   
   
   pTopSizer->Add (new wxStaticLine (this, -1, wxDefaultPosition, wxSize(3,3), wxHORIZONTAL), 0, wxEXPAND | wxALL, 5);
   
-  wxString asTitle[] = {"Median", "Mode", "Mean"};
+  wxString asTitle[] = {"Mode", "Median", "Mean"};
   
   m_pRadioBoxCenter = new wxRadioBox (this, -1, _T("Center"), wxDefaultPosition, wxDefaultSize, 3, asTitle, 1, wxRA_SPECIFY_COLS);
   m_pRadioBoxCenter->SetSelection (0);
   
   m_pRadioBoxCenter = new wxRadioBox (this, -1, _T("Center"), wxDefaultPosition, wxDefaultSize, 3, asTitle, 1, wxRA_SPECIFY_COLS);
   m_pRadioBoxCenter->SetSelection (0);
@@ -429,11 +488,11 @@ bool
 DialogAutoScaleParameters::getMinMax (double* pMin, double* pMax)
 {
   int iCenter = m_pRadioBoxCenter->GetSelection();
 DialogAutoScaleParameters::getMinMax (double* pMin, double* pMax)
 {
   int iCenter = m_pRadioBoxCenter->GetSelection();
-  double dCenter = m_dMedian;
+  double dCenter = m_dMode;
   if (iCenter == 1)
   if (iCenter == 1)
-    dCenter = m_dMode;
+    dCenter = m_dMedian;
   else if (iCenter == 2)
   else if (iCenter == 2)
-    dCenter = m_dMode;
+    dCenter = m_dMean;
   
   wxString sStddevFactor = m_pTextCtrlStdDevFactor->GetValue();
   double dValue;
   
   wxString sStddevFactor = m_pTextCtrlStdDevFactor->GetValue();
   double dValue;
@@ -471,11 +530,11 @@ DialogAutoScaleParameters::getAutoScaleFactor ()
 
 DialogGetRasterParameters::DialogGetRasterParameters 
    (wxWindow* pParent, int iDefaultXSize, int iDefaultYSize, int iDefaultNSamples, double dDefaultViewRatio)
 
 DialogGetRasterParameters::DialogGetRasterParameters 
    (wxWindow* pParent, int iDefaultXSize, int iDefaultYSize, int iDefaultNSamples, double dDefaultViewRatio)
-: wxDialog (pParent, -1, _T("Set Rasterization Parameters"), wxDefaultPosition, wxDefaultSize, wxDEFAULT_DIALOG_STYLE | wxCAPTION)
+: wxDialog (pParent, -1, _T("Rasterization Parameters"), wxDefaultPosition, wxDefaultSize, wxDEFAULT_DIALOG_STYLE | wxCAPTION)
 {
   wxBoxSizer* pTopSizer = new wxBoxSizer (wxVERTICAL);
   
 {
   wxBoxSizer* pTopSizer = new wxBoxSizer (wxVERTICAL);
   
-  pTopSizer->Add (new wxStaticText (this, -1, "Set Rasterization Parameters"), 0, wxALIGN_CENTER | wxTOP | wxLEFT | wxRIGHT, 5);
+  pTopSizer->Add (new wxStaticText (this, -1, "Rasterization Parameters"), 0, wxALIGN_CENTER | wxTOP | wxLEFT | wxRIGHT, 5);
   
   pTopSizer->Add (new wxStaticLine (this, -1, wxDefaultPosition, wxSize(3,3), wxHORIZONTAL), 0, wxEXPAND | wxALL, 5);
     
   
   pTopSizer->Add (new wxStaticLine (this, -1, wxDefaultPosition, wxSize(3,3), wxHORIZONTAL), 0, wxEXPAND | wxALL, 5);
     
@@ -580,10 +639,10 @@ DialogGetRasterParameters::getViewRatio ()
 
 
 DialogGetProjectionParameters::DialogGetProjectionParameters 
 
 
 DialogGetProjectionParameters::DialogGetProjectionParameters 
-   (wxWindow* pParent, int iDefaultNDet, int iDefaultNView, int iDefaultNSamples, 
+   (wxWindow* pParent, int iDefaultNDet, int iDefaultNView, int iDefaultOffsetView, int iDefaultNSamples, 
     double dDefaultRotAngle, double dDefaultFocalLength, double dDefaultCenterDetectorLength,
     double dDefaultViewRatio, double dDefaultScanRatio, int iDefaultGeometry, int iDefaultTrace)
     double dDefaultRotAngle, double dDefaultFocalLength, double dDefaultCenterDetectorLength,
     double dDefaultViewRatio, double dDefaultScanRatio, int iDefaultGeometry, int iDefaultTrace)
-: wxDialog (pParent, -1, _T("Set Projection Parameters"), wxDefaultPosition, wxDefaultSize, wxDEFAULT_DIALOG_STYLE | wxCAPTION)
+: wxDialog (pParent, -1, _T("Projection Parameters"), wxDefaultPosition, wxDefaultSize, wxDEFAULT_DIALOG_STYLE | wxCAPTION)
 {
   wxBoxSizer* pTopSizer = new wxBoxSizer (wxVERTICAL);
   
 {
   wxBoxSizer* pTopSizer = new wxBoxSizer (wxVERTICAL);
   
@@ -598,7 +657,7 @@ DialogGetProjectionParameters::DialogGetProjectionParameters
   m_iDefaultTrace = iDefaultTrace;
   m_iDefaultGeometry = iDefaultGeometry;
   
   m_iDefaultTrace = iDefaultTrace;
   m_iDefaultGeometry = iDefaultGeometry;
   
-  pTopSizer->Add (new wxStaticText (this, -1, "Set Projection Parameters"), 0, wxALIGN_CENTER | wxTOP | wxLEFT | wxRIGHT, 5);
+  pTopSizer->Add (new wxStaticText (this, -1, "Projection Parameters"), 0, wxALIGN_CENTER | wxTOP | wxLEFT | wxRIGHT, 5);
   
   pTopSizer->Add (new wxStaticLine (this, -1, wxDefaultPosition, wxSize(3,3), wxHORIZONTAL), 0, wxEXPAND | wxALL, 5);
     
   
   pTopSizer->Add (new wxStaticLine (this, -1, wxDefaultPosition, wxSize(3,3), wxHORIZONTAL), 0, wxEXPAND | wxALL, 5);
     
@@ -660,6 +719,13 @@ DialogGetProjectionParameters::DialogGetProjectionParameters
     m_pTextCtrlRotAngle = new wxTextCtrl (this, -1, osRotAngle.str().c_str(), wxDefaultPosition, wxSize(100, 25), 0);
     pText2Sizer->Add (new wxStaticText (this, -1, "Rotation Angle (Fraction of circle)"), 0, wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL);
     pText2Sizer->Add (m_pTextCtrlRotAngle, 0, wxALIGN_CENTER_VERTICAL);
     m_pTextCtrlRotAngle = new wxTextCtrl (this, -1, osRotAngle.str().c_str(), wxDefaultPosition, wxSize(100, 25), 0);
     pText2Sizer->Add (new wxStaticText (this, -1, "Rotation Angle (Fraction of circle)"), 0, wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL);
     pText2Sizer->Add (m_pTextCtrlRotAngle, 0, wxALIGN_CENTER_VERTICAL);
+                       
+    std::ostringstream osOffsetView;
+    osOffsetView << iDefaultOffsetView;
+    m_pTextCtrlOffsetView = new wxTextCtrl (this, -1, osOffsetView.str().c_str(), wxDefaultPosition, wxSize(100, 25), 0);
+    pText2Sizer->Add (new wxStaticText (this, -1, "Gantry offset in units of 'views' "), 0, wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL);
+    pText2Sizer->Add (m_pTextCtrlOffsetView, 0, wxALIGN_CENTER_VERTICAL);
+
   }
   pGridSizer->Add (pText2Sizer);
 
   }
   pGridSizer->Add (pText2Sizer);
 
@@ -713,6 +779,16 @@ DialogGetProjectionParameters::getNView ()
     return (m_iDefaultNView);
 }
 
     return (m_iDefaultNView);
 }
 
+unsigned int
+DialogGetProjectionParameters::getOffsetView ()
+{
+       wxString strCtrl = m_pTextCtrlOffsetView->GetValue();
+       unsigned long lValue;
+       if (strCtrl.ToULong (&lValue))
+         return lValue;
+       else
+         return (m_iDefaultOffsetView);
+}
 
 unsigned int
 DialogGetProjectionParameters::getNSamples ()
 
 unsigned int
 DialogGetProjectionParameters::getNSamples ()
@@ -817,7 +893,7 @@ DialogGetReconstructionParameters::DialogGetReconstructionParameters (wxWindow*
                      int iDefaultFilterMethodID, int iDefaultFilterGenerationID, int iDefaultZeropad, 
                      int iDefaultInterpID, int iDefaultInterpParam, int iDefaultBackprojectID, int iTrace,
                      ReconstructionROI* pDefaultROI)
                      int iDefaultFilterMethodID, int iDefaultFilterGenerationID, int iDefaultZeropad, 
                      int iDefaultInterpID, int iDefaultInterpParam, int iDefaultBackprojectID, int iTrace,
                      ReconstructionROI* pDefaultROI)
-: wxDialog (pParent, -1, _T("Set Reconstruction Parameters"), wxDefaultPosition, wxDefaultSize, wxDEFAULT_DIALOG_STYLE | wxCAPTION)
+: wxDialog (pParent, -1, _T("Reconstruction Parameters"), wxDefaultPosition, wxDefaultSize, wxDEFAULT_DIALOG_STYLE | wxCAPTION)
 {
   wxBoxSizer* pTopSizer = new wxBoxSizer (wxVERTICAL);
   
 {
   wxBoxSizer* pTopSizer = new wxBoxSizer (wxVERTICAL);
   
@@ -831,7 +907,7 @@ DialogGetReconstructionParameters::DialogGetReconstructionParameters (wxWindow*
   m_dDefaultRoiYMin = pDefaultROI->m_dYMin;
   m_dDefaultRoiYMax = pDefaultROI->m_dYMax;
 
   m_dDefaultRoiYMin = pDefaultROI->m_dYMin;
   m_dDefaultRoiYMax = pDefaultROI->m_dYMax;
 
-  pTopSizer->Add (new wxStaticText (this, -1, "Set Reconstruction Parameters"), 0, wxALIGN_CENTER | wxTOP | wxLEFT | wxRIGHT, 5);
+  pTopSizer->Add (new wxStaticText (this, -1, "Filtered Backprojection Parameters"), 0, wxALIGN_CENTER | wxTOP | wxLEFT | wxRIGHT, 5);
   pTopSizer->Add (new wxStaticLine (this, -1, wxDefaultPosition, wxSize(3,3), wxHORIZONTAL), 0, wxEXPAND | wxALL, 5);
   
   wxFlexGridSizer* pGridSizer = NULL;
   pTopSizer->Add (new wxStaticLine (this, -1, wxDefaultPosition, wxSize(3,3), wxHORIZONTAL), 0, wxEXPAND | wxALL, 5);
   
   wxFlexGridSizer* pGridSizer = NULL;
@@ -1131,11 +1207,11 @@ DialogGetReconstructionParameters::getROI (ReconstructionROI* pROI)
 
 
 DialogGetFilterParameters::DialogGetFilterParameters (wxWindow* pParent, int iDefaultXSize, int iDefaultYSize, int iDefaultFilterID, double dDefaultFilterParam,  double dDefaultBandwidth, int iDefaultDomainID, double dDefaultInputScale, double dDefaultOutputScale)
 
 
 DialogGetFilterParameters::DialogGetFilterParameters (wxWindow* pParent, int iDefaultXSize, int iDefaultYSize, int iDefaultFilterID, double dDefaultFilterParam,  double dDefaultBandwidth, int iDefaultDomainID, double dDefaultInputScale, double dDefaultOutputScale)
-: wxDialog (pParent, -1, _T("Set Filter Parameters"), wxDefaultPosition, wxDefaultSize, wxDEFAULT_DIALOG_STYLE | wxCAPTION)
+: wxDialog (pParent, -1, _T("Filter Parameters"), wxDefaultPosition, wxDefaultSize, wxDEFAULT_DIALOG_STYLE | wxCAPTION)
 {
   wxBoxSizer* pTopSizer = new wxBoxSizer (wxVERTICAL);
   
 {
   wxBoxSizer* pTopSizer = new wxBoxSizer (wxVERTICAL);
   
-  pTopSizer->Add (new wxStaticText (this, -1, "Set Filter Parameters"), 0, wxALIGN_CENTER | wxTOP | wxLEFT | wxRIGHT, 5); 
+  pTopSizer->Add (new wxStaticText (this, -1, "Filter Parameters"), 0, wxALIGN_CENTER | wxTOP | wxLEFT | wxRIGHT, 5); 
   pTopSizer->Add (new wxStaticLine (this, -1, wxDefaultPosition, wxSize(3,3), wxHORIZONTAL), 0, wxEXPAND | wxALL, 5);
   
   wxFlexGridSizer* pGridSizer = new wxFlexGridSizer (2);
   pTopSizer->Add (new wxStaticLine (this, -1, wxDefaultPosition, wxSize(3,3), wxHORIZONTAL), 0, wxEXPAND | wxALL, 5);
   
   wxFlexGridSizer* pGridSizer = new wxFlexGridSizer (2);
@@ -1462,7 +1538,7 @@ DialogGetXYSize::getYSize ()
 /////////////////////////////////////////////////////////////////////
 
 DialogGetConvertPolarParameters::DialogGetConvertPolarParameters (wxWindow* pParent, const char* const pszTitle, 
 /////////////////////////////////////////////////////////////////////
 
 DialogGetConvertPolarParameters::DialogGetConvertPolarParameters (wxWindow* pParent, const char* const pszTitle, 
-       int iDefaultXSize, int iDefaultYSize, int iDefaultInterpolationID, int iDefaultZeropad)
+       int iDefaultXSize, int iDefaultYSize, int iDefaultInterpolationID, int iDefaultZeropad, int iHelpID)
 : wxDialog (pParent, -1, _T(pszTitle), wxDefaultPosition, wxDefaultSize, wxDEFAULT_DIALOG_STYLE | wxCAPTION)
 {
   m_iDefaultXSize = iDefaultXSize;
 : wxDialog (pParent, -1, _T(pszTitle), wxDefaultPosition, wxDefaultSize, wxDEFAULT_DIALOG_STYLE | wxCAPTION)
 {
   m_iDefaultXSize = iDefaultXSize;
@@ -1491,15 +1567,13 @@ DialogGetConvertPolarParameters::DialogGetConvertPolarParameters (wxWindow* pPar
   m_pTextCtrlYSize = new wxTextCtrl (this, -1, osYSize.str().c_str(), wxDefaultPosition, wxSize(100, 25), 0);
   pTextGridSizer->Add (new wxStaticText (this, -1, "Y Size"), 0, wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL);
   pTextGridSizer->Add (m_pTextCtrlYSize, 0, wxALIGN_LEFT | wxALIGN_CENTER_VERTICAL);
   m_pTextCtrlYSize = new wxTextCtrl (this, -1, osYSize.str().c_str(), wxDefaultPosition, wxSize(100, 25), 0);
   pTextGridSizer->Add (new wxStaticText (this, -1, "Y Size"), 0, wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL);
   pTextGridSizer->Add (m_pTextCtrlYSize, 0, wxALIGN_LEFT | wxALIGN_CENTER_VERTICAL);
-#ifdef DEBUG
-  if (iDefaultZeropad >= 0) {
+  if (m_iDefaultZeropad >= 0) {
     std::ostringstream osZeropad;
     osZeropad << iDefaultZeropad;
     m_pTextCtrlZeropad = new wxTextCtrl (this, -1, osZeropad.str().c_str(), wxDefaultPosition, wxSize(100, 25), 0);
     pTextGridSizer->Add (new wxStaticText (this, -1, "Zeropad"), 0, wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL);
     pTextGridSizer->Add (m_pTextCtrlZeropad, 0, wxALIGN_LEFT | wxALIGN_CENTER_VERTICAL);
   }
     std::ostringstream osZeropad;
     osZeropad << iDefaultZeropad;
     m_pTextCtrlZeropad = new wxTextCtrl (this, -1, osZeropad.str().c_str(), wxDefaultPosition, wxSize(100, 25), 0);
     pTextGridSizer->Add (new wxStaticText (this, -1, "Zeropad"), 0, wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL);
     pTextGridSizer->Add (m_pTextCtrlZeropad, 0, wxALIGN_LEFT | wxALIGN_CENTER_VERTICAL);
   }
-#endif
 
   pGridSizer->Add (pTextGridSizer, 0, wxALIGN_CENTER | wxALL);
 
 
   pGridSizer->Add (pTextGridSizer, 0, wxALIGN_CENTER | wxALL);
 
@@ -1512,7 +1586,7 @@ DialogGetConvertPolarParameters::DialogGetConvertPolarParameters (wxWindow* pPar
   pButtonSizer->Add (pButtonOk, 0, wxEXPAND | wxALL, 10);
   wxButton* pButtonCancel = new wxButton (this, wxID_CANCEL, "Cancel");
   pButtonSizer->Add (pButtonCancel, 0, wxEXPAND | wxALL, 10);
   pButtonSizer->Add (pButtonOk, 0, wxEXPAND | wxALL, 10);
   wxButton* pButtonCancel = new wxButton (this, wxID_CANCEL, "Cancel");
   pButtonSizer->Add (pButtonCancel, 0, wxEXPAND | wxALL, 10);
-  CTSimHelpButton* pButtonHelp = new CTSimHelpButton (this, IDH_DLG_POLAR);
+  CTSimHelpButton* pButtonHelp = new CTSimHelpButton (this, iHelpID);
   pButtonSizer->Add (pButtonHelp, 0, wxEXPAND | wxALL, 10);
   
   pTopSizer->Add (pButtonSizer, 0, wxALIGN_CENTER);
   pButtonSizer->Add (pButtonHelp, 0, wxEXPAND | wxALL, 10);
   
   pTopSizer->Add (pButtonSizer, 0, wxALIGN_CENTER);
@@ -1555,16 +1629,15 @@ DialogGetConvertPolarParameters::getYSize ()
 unsigned int
 DialogGetConvertPolarParameters::getZeropad ()
 {
 unsigned int
 DialogGetConvertPolarParameters::getZeropad ()
 {
-#ifdef DEBUG
-  wxString strCtrl = m_pTextCtrlZeropad->GetValue();
-  unsigned long lValue;
-  if (strCtrl.ToULong (&lValue))
-    return lValue;
-  else
-    return (m_iDefaultZeropad);
-#else
-  return 0;
-#endif
+  if (m_iDefaultZeropad >= 0) {
+    wxString strCtrl = m_pTextCtrlZeropad->GetValue();
+    unsigned long lValue;
+    if (strCtrl.ToULong (&lValue))
+      return lValue;
+    else
+      return (m_iDefaultZeropad);
+  } else
+    return 0;
 }
 
 const char*
 }
 
 const char*