]> git.lyx.org Git - features.git/commitdiff
remove CXX_WORKING_NAMESPACES
authorLars Gullik Bjønnes <larsbj@gullik.org>
Thu, 15 Mar 2001 18:21:56 +0000 (18:21 +0000)
committerLars Gullik Bjønnes <larsbj@gullik.org>
Thu, 15 Mar 2001 18:21:56 +0000 (18:21 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@1777 a592a061-630c-0410-9148-cb99ea01b6c8

84 files changed:
src/BufferView_pimpl.C
src/BufferView_pimpl.h
src/ChangeLog
src/LyXView.C
src/LyXView.h
src/WorkArea.h
src/counters.C
src/counters.h
src/frontends/ChangeLog
src/frontends/DialogBase.h
src/frontends/Liason.C
src/frontends/Liason.h
src/frontends/Timeout.h
src/frontends/controllers/ChangeLog
src/frontends/controllers/ControlConnections.C
src/frontends/controllers/ControlConnections.h
src/frontends/gnome/ChangeLog
src/frontends/gnome/FormCitation.C
src/frontends/gnome/FormPrint.C
src/frontends/gnome/FormPrint.h
src/frontends/gnome/FormRef.C
src/frontends/gnome/FormRef.h
src/frontends/gnome/FormToc.C
src/frontends/gnome/Menubar_pimpl.C
src/frontends/gnome/Menubar_pimpl.h
src/frontends/kde/ChangeLog
src/frontends/kde/FormDocument.C
src/frontends/kde/FormParagraph.C
src/frontends/kde/FormPrint.C
src/frontends/kde/FormPrint.h
src/frontends/kde/citationdlg.C
src/frontends/kde/dlg/helpers.C
src/frontends/kde/dlg/helpers.h
src/frontends/kde/docdlg.C
src/frontends/kde/paradlg.C
src/frontends/kde/paraextradlg.C
src/frontends/kde/parageneraldlg.C
src/frontends/kde/refdlg.C
src/frontends/kde/tocdlg.C
src/frontends/kde/urldlg.C
src/frontends/qt2/ChangeLog
src/frontends/qt2/FormCharacter.C
src/frontends/qt2/FormParagraph.C
src/frontends/qt2/FormPrint.C
src/frontends/qt2/FormPrint.h
src/frontends/qt2/FormSearch.C
src/frontends/xforms/ChangeLog
src/frontends/xforms/Dialogs.C
src/frontends/xforms/FormBaseDeprecated.h
src/frontends/xforms/FormBrowser.C
src/frontends/xforms/FormCharacter.C
src/frontends/xforms/FormDocument.C
src/frontends/xforms/FormExternal.h
src/frontends/xforms/FormFiledialog.C
src/frontends/xforms/FormFiledialog.h
src/frontends/xforms/FormInclude.h
src/frontends/xforms/FormInset.h
src/frontends/xforms/FormLog.C
src/frontends/xforms/FormParagraph.C
src/frontends/xforms/FormPreamble.C
src/frontends/xforms/FormPrint.C
src/frontends/xforms/FormSearch.C
src/frontends/xforms/FormSplash.h
src/frontends/xforms/FormVCLog.C
src/graphics/GraphicsCacheItem.h
src/insets/ChangeLog
src/insets/figinset.C
src/insets/figinset.h
src/insets/insetcommand.h
src/insets/inseterror.h
src/insets/insetexternal.C
src/insets/insetexternal.h
src/insets/insetgraphics.h
src/insets/insetinclude.h
src/insets/insettabular.h
src/intl.C
src/intl.h
src/minibuffer.C
src/minibuffer.h
src/support/ChangeLog
src/support/kill.C
src/support/lyxlib.h
src/support/putenv.C
src/support/sstream.h

index 28734f6ce8f84412ecfee2132a996915c5101ec0..36cfdc9d3a5535172c58d8551202caed8a0b3cfe 100644 (file)
@@ -61,10 +61,6 @@ extern void math_insert_symbol(BufferView *, string const &);
 extern bool math_insert_greek(BufferView *, char);
 extern int greek_kb_flag;
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::slot;
-#endif
-
 using std::vector;
 using std::find_if;
 using std::pair;
index be5fe4f2c835d2e8206a93fa00e8ee37b07b287a..e7a9c8ba750b0108d3bd656c8ba707e28131b513 100644 (file)
@@ -19,12 +19,8 @@ class LyXView;
 class WorkArea;
 class LyXScreen;
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Object;
-#endif
-
 ///
-struct BufferView::Pimpl : public Object {
+struct BufferView::Pimpl : public SigC::Object {
        ///
        Pimpl(BufferView * i, LyXView * o,
              int xpos, int ypos, int width, int height);
index 786f593da877d26d3ae9eedbf1fbc9183c8ca500..dc0b31d8de1f83238e001cca01d1364fa7d2f1e6 100644 (file)
@@ -1,5 +1,7 @@
 2001-03-15  Lars Gullik Bjønnes  <larsbj@trylle.birdstep.com>
 
+       * several files: remove CXX_WORKING_NAMESPACES
+
        * buffer.C (pop_tag): tie is in namespace boost
 
        * BufferView.h: noncopyable is in namespace boost
index 8a43792b13401682c12dfc1cb5230deb2de856db..6cd4ae26ccb6a2960ef5a0428bac10529d799a5d 100644 (file)
@@ -50,10 +50,6 @@ BufferView * current_view;
 
 extern "C" int C_LyXView_atCloseMainFormCB(FL_FORM *, void *);
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Connection;
-using SigC::slot;
-#endif
 
 LyXView::LyXView(int width, int height)
 {
@@ -70,11 +66,11 @@ LyXView::LyXView(int width, int height)
        dialogs_ = new Dialogs(this);
        // temporary until all dialogs moved into Dialogs.
        dialogs_->updateBufferDependent
-               .connect(slot(&updateAllVisibleBufferRelatedDialogs));
+               .connect(SigC::slot(&updateAllVisibleBufferRelatedDialogs));
        dialogs_->hideBufferDependent
-               .connect(slot(&CloseAllBufferRelatedDialogs));
-       Dialogs::redrawGUI.connect(slot(this, &LyXView::redraw));
-       Dialogs::redrawGUI.connect(slot(&RedrawAllBufferRelatedDialogs));
+               .connect(SigC::slot(&CloseAllBufferRelatedDialogs));
+       Dialogs::redrawGUI.connect(SigC::slot(this, &LyXView::redraw));
+       Dialogs::redrawGUI.connect(SigC::slot(&RedrawAllBufferRelatedDialogs));
 }
 
 
@@ -274,7 +270,7 @@ void LyXView::create_form_form_main(int width, int height)
        // TIMERS
        //
 
-       autosave_timeout.timeout.connect(slot(this, &LyXView::AutoSave));
+       autosave_timeout.timeout.connect(SigC::slot(this, &LyXView::AutoSave));
        
        //
        // Misc
index 220e3cb1b715430c686eab5e4a49b87bf4f801e5..d82a83c504cf65ef5ab4f2028ed6379eafdbd931 100644 (file)
@@ -34,17 +34,12 @@ class Menubar;
 class BufferView;
 class Dialogs;
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Object;
-#endif
-
-
 /**
   This class is the form containing the view of the buffer. The actual buffer
   view is supposed (at least IMHO) to be another class, that shows its output
   in one or more LyXView's.
  */
-class LyXView : public Object, public boost::noncopyable {
+class LyXView : public SigC::Object, public boost::noncopyable {
 public:
        /// constructor
        LyXView(int w, int h);
index 7c00df597da8480065aa6e0f56b4d9b5d69df6c2..dc3e26a5413d2bcd4fc5a4296c1b38f7e4787acd 100644 (file)
 #include FORMS_H_LOCATION
 #include "Painter.h"
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Signal0;
-using SigC::Signal1;
-using SigC::Signal2;
-using SigC::Signal3;
-#endif
-
-
 ///
 class WorkArea {
 public:
@@ -105,29 +97,29 @@ public:
        void putClipboard(string const &) const;
        // Signals
        ///
-       Signal0<void> workAreaExpose;
+       SigC::Signal0<void> workAreaExpose;
        ///
-       Signal1<void, double> scrollCB;
+       SigC::Signal1<void, double> scrollCB;
        ///
-       Signal2<void, KeySym, unsigned int> workAreaKeyPress;
+       SigC::Signal2<void, KeySym, unsigned int> workAreaKeyPress;
        ///
-       Signal3<void, int, int, unsigned int> workAreaButtonPress;
+       SigC::Signal3<void, int, int, unsigned int> workAreaButtonPress;
        ///
-       Signal3<void, int, int, unsigned int> workAreaButtonRelease;
+       SigC::Signal3<void, int, int, unsigned int> workAreaButtonRelease;
        ///
-       Signal3<void, int, int, unsigned int> workAreaMotionNotify;
+       SigC::Signal3<void, int, int, unsigned int> workAreaMotionNotify;
        ///
-       Signal0<void> workAreaFocus;
+       SigC::Signal0<void> workAreaFocus;
        ///
-       Signal0<void> workAreaUnfocus;
+       SigC::Signal0<void> workAreaUnfocus;
        ///
-       Signal0<void> workAreaEnter;
+       SigC::Signal0<void> workAreaEnter;
        ///
-       Signal0<void> workAreaLeave;
+       SigC::Signal0<void> workAreaLeave;
        ///
-       Signal3<void, int, int, unsigned int> workAreaDoubleClick;
+       SigC::Signal3<void, int, int, unsigned int> workAreaDoubleClick;
        ///
-       Signal3<void, int, int, unsigned int> workAreaTripleClick;
+       SigC::Signal3<void, int, int, unsigned int> workAreaTripleClick;
 private:
        ///
        void createPixmap(int, int);
index 211791f981356b76490a0684be0c1b82beef2c15..4d2a8c683217d081492d7f600e7f8c679b8d5a21 100644 (file)
 #include "counters.h"
 #include "debug.h"
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Connection;
-using SigC::slot;
-#endif
-
 using std::endl;
 
 
@@ -105,7 +100,7 @@ void Counters::newCounter(string const & newc, string const & oldc)
        }
 
        Counter * tmp = new Counter;
-       (*it).second->onstep.connect(slot(tmp,
+       (*it).second->onstep.connect(SigC::slot(tmp,
                                         &Counter::reset));
        counterList[newc] = tmp;
 }
index fc0e82a2ac704e31033f32ed145f0722f2c193d8..9d50608493b22dddc44b46386e92feccb25486eb 100644 (file)
 #include <sigc++/signal_system.h>
 #include "LString.h"
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Object;
-using SigC::Signal0;
-#endif
-
-
 ///
-class Counter : public Object {
+class Counter : public SigC::Object {
 public:
        ///
        Counter();
@@ -44,7 +38,7 @@ public:
        ///
        void reset();
        ///
-       Signal0<void> onstep;
+       SigC::Signal0<void> onstep;
 private:
        ///
        int value_;
index 67c03dcd797b1c5e250d48bda6c57420aa878fbb..a071664c5a89fc67b036b5fac2cf605315b3337f 100644 (file)
@@ -1,5 +1,7 @@
 2001-03-15  Lars Gullik Bjønnes  <larsbj@trylle.birdstep.com>
 
+       * several files: remove CXX_WORKING_NAMESPACES
+
        * ButtonPolicies.h: noncopyable is in namespace boost
        * Dialogs.h (noncopyable): ditto
        * DialogBase.h (noncopyable): ditto
index 457824a4a4ee2989219507a01378932100eced47..72d1a982f18568609b95286c458220b697f7e145 100644 (file)
 #include <sigc++/signal_system.h>
 #include <boost/utility.hpp>
 
-// If we do not want to bring them in global namespace, they could be
-// defined inside DialogBase... (JMarc) 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Connection;
-using SigC::slot;
-using SigC::Object;
-#endif
-
-
 /** Abstract base class of all dialogs.
     The outside world only needs some way to tell a dialog when to show, hide
     or update itself.  A dialog then takes whatever steps are necessary to
     satisfy that request.  Thus a dialog will have to "pull" the necessary
     details from the core of the program.
  */
-class DialogBase : public Object, public boost::noncopyable
+class DialogBase : public SigC::Object, public boost::noncopyable
 {
 public:
        /**@name Constructors and Deconstructors */
index f4f09dea4ef050653c2622ebae040e8b4bfc44a0..3b17230a6c20da4a20a39edab59367d9f7397e5c 100644 (file)
@@ -33,10 +33,7 @@ using std::endl;
 
 extern LyXRC lyxrc;
 
-#ifdef CXX_WORKING_NAMESPACES
-namespace Liason 
-{
-#endif
+namespace Liason {
 
 PrinterParams getPrinterParams(Buffer * buffer)
 {
@@ -162,7 +159,4 @@ void setMinibuffer(LyXView * lv, char const * msg)
        lv->getMiniBuffer()->Set(msg);
 }
 
-#ifdef CXX_WORKING_NAMESPACES
-}
-#endif
-
+} // namespace Liason
index 77aceddb2dcfc7c04754c0598b677e53c84153ca..c40b4277aee787778202a6d7e890953c8cea7541 100644 (file)
@@ -44,10 +44,7 @@ class BufferParams;
     worked so nicely on a very small number of compilers and systems.
     See the "dialogbase" branch of lyx-devel cvs module for xtl implementation.
 */
-#ifdef CXX_WORKING_NAMESPACES
-namespace Liason
-{
-#endif
+namespace Liason {
        /**@name Global support functions */
        //@{
        /// get global printer parameters
@@ -58,8 +55,9 @@ namespace Liason
        void setMinibuffer(LyXView *, char const  * msg);
        //@}
 
-#ifdef CXX_WORKING_NAMESPACES
-}
+} // namespace Liason
 #endif
 
-#endif
+
+
+
index 717096f83ef8b46b1605961f8fcb635c13bdf15a..f9c54cc940ab9c049bb4fa91e9f099f62cbe9853 100644 (file)
 
 #include <sigc++/signal_system.h>
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Signal0;
-#endif
-
 /**
  * This class executes the callback when the timeout expires.
  */
@@ -46,7 +42,7 @@ public:
        /// restart the timer
        void restart();
        /// signal emitted on timer expiry
-       Signal0<void> timeout;
+       SigC::Signal0<void> timeout;
        /// emit the signal
        void emit();
        /// set the timer type
index 316cdf5bd30ed4f2afe7fd37569b9f6c651b5fad..e89ad973baacd8d12815234eec194edcb6785cd3 100644 (file)
@@ -1,5 +1,7 @@
 2001-03-15  Lars Gullik Bjønnes  <larsbj@trylle.birdstep.com>
 
+       * several files: remove CXX_WORKING_NAMESPACES
+
        * ButtonController.h: noncopyable is in namespace boost
        * ButtonPolicies.h: ditto
 
index b9511cdf6ce073902c7a7a1804705f747618f5c1..c4df523187b6a57ed3629f66b70fcdc36c7fd257 100644 (file)
 #include "ViewBase.h"
 #include "insets/lyxinset.h"
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::slot;
-#endif
-
 ControlConnectBase::ControlConnectBase(LyXView & lv, Dialogs & d)
        : ControlBase(lv),
          d_(d), h_(0), r_(0)
index ad68dc117c19d15a82ad9dff027bc9fc969714f3..f50601241e990aa3b7261a428057792a0348b4ae 100644 (file)
@@ -45,9 +45,9 @@ protected:
        /// Contains the signals we have to connect to.
        Dialogs & d_;
        /// Hide connection.
-       Connection h_;
+       SigC::Connection h_;
        /// Redraw connection.
-       Connection r_;
+       SigC::Connection r_;
 };
 
 
@@ -91,7 +91,7 @@ protected:
 
 private:
        /// Update connection.
-       Connection u_;
+       SigC::Connection u_;
 };
 
 /** Base class to control connection/disconnection of signals with the LyX
@@ -122,14 +122,14 @@ protected:
 
 private:
        /// inset::hide connection.
-       Connection ih_;
+       SigC::Connection ih_;
 };
 
 
 template <class Inset>
 ControlConnectInset<Inset>::ControlConnectInset(LyXView & lv, Dialogs & d)
        : ControlConnectBD(lv, d),
-         ih_(0), inset_(0)
+         inset_(0), ih_(0)
 {}
 
 
index bd42dbf9fc68745dff66098765019be9caaaa1da..2748fdedb4e53bab95efcb1485ef0e4dfc292efd 100644 (file)
@@ -1,3 +1,7 @@
+2001-03-15  Lars Gullik Bjønnes  <larsbj@trylle.birdstep.com>
+
+       * several files: remove CXX_WORKING_NAMESPACES
+
 2001-03-11  Baruch Even  <baruch@lyx.org>
 
        * Various files: More fixes to get it compiled again.
index 773a948de87975324c17d12c110397f1a6c07608..d602ba1ac4992f9fecd660d744198b7edca6b2ea 100644 (file)
@@ -49,12 +49,6 @@ using std::max;
 using std::min;
 using std::find;
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::slot;
-using SigC::bind;
-#endif
-
-
 // configuration keys
 static string const  LOCAL_CONFIGURE_PREFIX("FormCitation");
 
@@ -76,8 +70,8 @@ FormCitation::FormCitation(LyXView * lv, Dialogs * d)
   // let the dialog be shown
   // These are permanent connections so we won't bother
   // storing a copy because we won't be disconnecting.
-  d->showCitation.connect(slot(this, &FormCitation::showInset));
-  d->createCitation.connect(slot(this, &FormCitation::createInset));
+  d->showCitation.connect(SigC::slot(this, &FormCitation::showInset));
+  d->createCitation.connect(SigC::slot(this, &FormCitation::createInset));
 
   cleanupWidgets();
 }
@@ -92,10 +86,10 @@ void FormCitation::showInset( InsetCommand * const inset )
   if( dialog_!=0 || inset == 0 ) return;
   
   inset_ = inset;
-  ih_ = inset_->hideDialog.connect(slot(this, &FormCitation::hide));
+  ih_ = inset_->hideDialog.connect(SigC::slot(this, &FormCitation::hide));
 
-  u_ = d_->updateBufferDependent.connect(slot(this, &FormCitation::updateSlot));
-  h_ = d_->hideBufferDependent.connect(slot(this, &FormCitation::hide));
+  u_ = d_->updateBufferDependent.connect(SigC::slot(this, &FormCitation::updateSlot));
+  h_ = d_->hideBufferDependent.connect(SigC::slot(this, &FormCitation::hide));
   
   params = inset->params();
 
@@ -108,8 +102,8 @@ void FormCitation::createInset( string const & arg )
 {
   if( dialog_!=0 ) return;
   
-  u_ = d_->updateBufferDependent.connect(slot(this, &FormCitation::updateSlot)); 
-  h_ = d_->hideBufferDependent.connect(slot(this, &FormCitation::hide));
+  u_ = d_->updateBufferDependent.connect(SigC::slot(this, &FormCitation::updateSlot)); 
+  h_ = d_->hideBufferDependent.connect(SigC::slot(this, &FormCitation::hide));
   
   params.setFromString( arg );
   showStageSearch();
@@ -117,12 +111,13 @@ void FormCitation::createInset( string const & arg )
 
 
 static
-void parseBibTeX(string data,
+void parseBibTeX(string const & dat,
                 string const & findkey,
                 string & keyvalue)
 {
   unsigned int i;
-
+  string data(dat);
+  
   keyvalue = "";
   
   for (i=0; i<data.length(); ++i)
@@ -137,7 +132,8 @@ void parseBibTeX(string data,
     {
       unsigned int keypos = min(data.find(' '), data.find('='));
       string key = lowercase( data.substr(0, keypos) );
-      string value, tmp;
+      string value;
+      string tmp;
       char enclosing;
       
       data = data.substr(keypos, data.length()-1);
@@ -478,11 +474,11 @@ void FormCitation::showStageSearch()
       gtk_widget_grab_default (GTK_WIDGET(search_text_->get_entry()->gtkobj()));
 
       // connecting signals
-      b_ok->clicked.connect(slot(this, &FormCitation::moveFromSearchToSelect));
-      search_text_->get_entry()->activate.connect(slot(this, &FormCitation::moveFromSearchToSelect));
+      b_ok->clicked.connect(SigC::slot(this, &FormCitation::moveFromSearchToSelect));
+      search_text_->get_entry()->activate.connect(SigC::slot(this, &FormCitation::moveFromSearchToSelect));
 
-      b_cancel->clicked.connect(slot(mainAppWin, &GLyxAppWin::remove_action));
-      dialog_->destroy.connect(slot(this, &FormCitation::free));
+      b_cancel->clicked.connect(SigC::slot(mainAppWin, &GLyxAppWin::remove_action));
+      dialog_->destroy.connect(SigC::slot(this, &FormCitation::free));
     }
 }
 
@@ -569,17 +565,17 @@ void FormCitation::showStageSelect()
       gtk_widget_grab_default (GTK_WIDGET(b_ok->gtkobj()));
 
       // connecting signals
-      b_ok->clicked.connect(slot(this, &FormCitation::applySelect));
-      text_after_->get_entry()->activate.connect(slot(this, &FormCitation::applySelect));
+      b_ok->clicked.connect(SigC::slot(this, &FormCitation::applySelect));
+      text_after_->get_entry()->activate.connect(SigC::slot(this, &FormCitation::applySelect));
 
-      b_cancel->clicked.connect(slot(mainAppWin, &GLyxAppWin::remove_action));
+      b_cancel->clicked.connect(SigC::slot(mainAppWin, &GLyxAppWin::remove_action));
 
-      dialog_->destroy.connect(slot(this, &FormCitation::free));
+      dialog_->destroy.connect(SigC::slot(this, &FormCitation::free));
 
-      clist_bib_->click_column.connect(slot(this, &FormCitation::sortBibList));
-      clist_bib_->select_row.connect(bind(slot(this, &FormCitation::selectionToggled),
+      clist_bib_->click_column.connect(SigC::slot(this, &FormCitation::sortBibList));
+      clist_bib_->select_row.connect(SigC::bind(SigC::slot(this, &FormCitation::selectionToggled),
                                          true, false));
-      clist_bib_->unselect_row.connect(bind(slot(this, &FormCitation::selectionToggled),
+      clist_bib_->unselect_row.connect(SigC::bind(SigC::slot(this, &FormCitation::selectionToggled),
                                            false, false));
     }
 }
@@ -666,20 +662,20 @@ void FormCitation::showStageEdit()
       gtk_widget_grab_default (GTK_WIDGET(b_ok->gtkobj()));
 
       // connecting signals
-      b_ok->clicked.connect(slot(this, &FormCitation::applyEdit));
-      text_after_->get_entry()->activate.connect(slot(this, &FormCitation::applyEdit));
+      b_ok->clicked.connect(SigC::slot(this, &FormCitation::applyEdit));
+      text_after_->get_entry()->activate.connect(SigC::slot(this, &FormCitation::applyEdit));
 
-      b_cancel->clicked.connect(slot(mainAppWin, &GLyxAppWin::remove_action));
+      b_cancel->clicked.connect(SigC::slot(mainAppWin, &GLyxAppWin::remove_action));
 
-      dialog_->destroy.connect(slot(this, &FormCitation::free));
+      dialog_->destroy.connect(SigC::slot(this, &FormCitation::free));
 
-      button_unselect_->clicked.connect(slot(this, &FormCitation::removeCitation));
-      button_up_->clicked.connect(slot(this, &FormCitation::moveCitationUp));
-      button_down_->clicked.connect(slot(this, &FormCitation::moveCitationDown));      
+      button_unselect_->clicked.connect(SigC::slot(this, &FormCitation::removeCitation));
+      button_up_->clicked.connect(SigC::slot(this, &FormCitation::moveCitationUp));
+      button_down_->clicked.connect(SigC::slot(this, &FormCitation::moveCitationDown));      
 
-      clist_selected_->select_row.connect(bind(slot(this, &FormCitation::selectionToggled),
+      clist_selected_->select_row.connect(SigC::bind(SigC::slot(this, &FormCitation::selectionToggled),
                                          true, true));
-      clist_selected_->unselect_row.connect(bind(slot(this, &FormCitation::selectionToggled),
+      clist_selected_->unselect_row.connect(SigC::bind(SigC::slot(this, &FormCitation::selectionToggled),
                                            false, true));
     }
 }
@@ -808,13 +804,10 @@ void FormCitation::applySelect()
 {
   if( lv_->buffer()->isReadonly() ) return;
 
-  string contents;
-  int sz;
-
-  contents = frontStrip( strip(params.getContents()) );
+  string contents = frontStrip( strip(params.getContents()) );
   if (!contents.empty()) contents += ", ";
   
-  sz = clist_bib_->selection().size();
+  int sz = clist_bib_->selection().size();
   for (int i=0; i < sz; ++i)
     {
       if (i > 0) contents += ", ";
@@ -894,7 +887,7 @@ void FormCitation::search()
 // looking for entries which match regexp
 void FormCitation::searchReg()
 {
-  string tmp, rexptxt( search_string_ );
+  string rexptxt(search_string_);
   rexptxt = frontStrip( strip( rexptxt ) );
   
   LRegex reg(rexptxt);
@@ -908,7 +901,7 @@ void FormCitation::searchReg()
   bool additem;
   for ( int i = 0; i < sz; ++i )
     {
-      string data = bibkeys[i] + bibkeysInfo[i];
+      string const data = bibkeys[i] + bibkeysInfo[i];
 
       if (rexptxt.empty()) additem = true;
       else additem = (reg.exec(data).size() > 0);
index d45af3cd05024190b2d04b0574368b8b2c64c6b0..3418b1732d141dcaa8eab96fcd5feb5a061d85b2 100644 (file)
@@ -37,15 +37,8 @@ extern "C" {
 #include <gtk--/base.h>
 #include <gtk--/button.h>
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::slot;
-using SigC::bind;
-#endif
-
-#ifdef CXX_WORKING_NAMESPACES
 using Liason::printBuffer;
 using Liason::getPrinterParams;
-#endif
 
 FormPrint::FormPrint(LyXView * lv, Dialogs * d)
   : dialog_(0), lv_(lv), d_(d), u_(0), h_(0)
@@ -53,7 +46,7 @@ FormPrint::FormPrint(LyXView * lv, Dialogs * d)
   // let the dialog be shown
   // This is a permanent connection so we won't bother
   // storing a copy because we won't be disconnecting.
-  d->showPrint.connect(slot(this,&FormPrint::show));
+  d->showPrint.connect(SigC::slot(this,&FormPrint::show));
 }
 
 
@@ -97,12 +90,12 @@ void FormPrint::show()
       b_cancel = Gtk::wrap( GTK_BUTTON( lookup_widget(pd, "button_cancel") ) );
 
       // setting up connections
-      b_ok->clicked.connect(slot(this, &FormPrint::apply));
+      b_ok->clicked.connect(SigC::slot(this, &FormPrint::apply));
       b_ok->clicked.connect(dialog_->destroy.slot());
       b_cancel->clicked.connect(dialog_->destroy.slot());
-      dialog_->destroy.connect(slot(this, &FormPrint::free));
+      dialog_->destroy.connect(SigC::slot(this, &FormPrint::free));
 
-      u_ = d_->updateBufferDependent.connect(slot(this,
+      u_ = d_->updateBufferDependent.connect(SigC::slot(this,
                                                  &FormPrint::updateSlot));
       h_ = d_->hideBufferDependent.connect(dialog_->destroy.slot());
 
index 18a853a8a61f4861e3ef02e270ae8c1b62777691..ab90e572e24354dd5c5f26438bc06f6c5299d5f7 100644 (file)
 class LyXView;
 class Dialogs;
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Connection;
-#endif
-
 /** This class provides an Gnome implementation of the FormPrint Dialog.
     The print dialog allows users to print their documents.
  */
@@ -99,9 +95,9 @@ private:
   LyXView * lv_;
   Dialogs * d_;
   /// Update connection.
-  Connection u_;
+  SigC::Connection u_;
   /// Hide connection.
-  Connection h_;
+  SigC::Connection h_;
   //@}
 };
 
index c69e96a4872aae39965029cc9cfa202cbd023487..ac5a6392d581ccffa8162a8aa147b8a38ba99948 100644 (file)
@@ -39,8 +39,6 @@
 #include "mainapp.h"
 extern GLyxAppWin * mainAppWin;
 
-using SigC::bind;
-
 // configuration keys
 static string const CONF_ENTRY_NAME("FormRef_name");
 
index d9b8e6799079965bb218a5d93de297bd75d5a495..22a214fdbc4308099cbb72d9b0d7b08dcda891da 100644 (file)
@@ -114,11 +114,11 @@ private:
   /// the nitty-griity. What is modified and passed back
   InsetCommandParams params;
   /// Update connection.
-  Connection u_;
+  SigC::Connection u_;
   /// Hide connection.
-  Connection h_;
+  SigC::Connection h_;
   /// inset::hide connection.
-  Connection ih_;
+  SigC::Connection ih_;
   /// 
   std::vector<string> refs;
   ///
index f5ede35ed6b455430c9d0f0ca7c5cbbae21deae2..8e19debeeefa330ae3d8979864d8b0016f1ba41d 100644 (file)
@@ -37,16 +37,15 @@ extern "C" {
 #include <gtk--/menu.h>
 #include <gtk--/menuitem.h>
 
-using SigC::bind;
-
 FormToc::FormToc(LyXView * lv, Dialogs * d)
-  : lv_(lv), d_(d), inset_(0), u_(0), h_(0), ih_(0), dialog_(0), ignore_callback_(false)
+  : lv_(lv), d_(d), inset_(0), u_(0), h_(0), ih_(0), dialog_(0),
+    ignore_callback_(false)
 {
   // let the dialog be shown
   // These are permanent connections so we won't bother
   // storing a copy because we won't be disconnecting.
-  d->showTOC.connect(slot(this, &FormToc::showInset));
-  d->createTOC.connect(slot(this, &FormToc::createInset));
+  d->showTOC.connect(SigC::slot(this, &FormToc::showInset));
+  d->createTOC.connect(SigC::slot(this, &FormToc::createInset));
 }
 
 
@@ -57,10 +56,10 @@ FormToc::~FormToc()
 
 void FormToc::showInset( InsetCommand * const inset )
 {
-  if( dialog_!=0 || inset == 0 ) return;
+  if ( dialog_!=0 || inset == 0 ) return;
   
   inset_ = inset;
-  ih_ = inset_->hideDialog.connect(slot(this, &FormToc::hide));
+  ih_ = inset_->hideDialog.connect(SigC::slot(this, &FormToc::hide));
   
   params = inset->params();
   show();
@@ -99,31 +98,31 @@ void FormToc::show()
       choice_->get_menu()->items().clear();
       
       e = manage( new Gtk::MenuItem(_("Table of Contents")) );
-      e->activate.connect(bind<Buffer::TocType>(slot(this, &FormToc::changeList), Buffer::TOC_TOC));
+      e->activate.connect(SigC::bind<Buffer::TocType>(SigC::slot(this, &FormToc::changeList), Buffer::TOC_TOC));
       choice_->get_menu()->append( *e );
 
       e = manage( new Gtk::MenuItem(_("List of Figures")) );
-      e->activate.connect(bind<Buffer::TocType>(slot(this, &FormToc::changeList), Buffer::TOC_LOF));
+      e->activate.connect(SigC::bind<Buffer::TocType>(SigC::slot(this, &FormToc::changeList), Buffer::TOC_LOF));
       choice_->get_menu()->append( *e );
 
       e = manage( new Gtk::MenuItem(_("List of Tables")) );
-      e->activate.connect(bind<Buffer::TocType>(slot(this, &FormToc::changeList), Buffer::TOC_LOT));
+      e->activate.connect(SigC::bind<Buffer::TocType>(SigC::slot(this, &FormToc::changeList), Buffer::TOC_LOT));
       choice_->get_menu()->append( *e );
 
       e = manage( new Gtk::MenuItem(_("List of Algorithms")) );
-      e->activate.connect(bind<Buffer::TocType>(slot(this, &FormToc::changeList), Buffer::TOC_LOA));
+      e->activate.connect(SigC::bind<Buffer::TocType>(SigC::slot(this, &FormToc::changeList), Buffer::TOC_LOA));
       choice_->get_menu()->append( *e );
 
       // wrap buttons and connect slots
       b_refresh = Gtk::wrap( GTK_BUTTON( lookup_widget(pd, "button_refresh") ) );
       b_close   = Gtk::wrap( GTK_BUTTON( lookup_widget(pd, "button_close") ) );
       
-      b_refresh->clicked.connect(bind<bool>(slot(this, &FormToc::updateSlot),false));
+      b_refresh->clicked.connect(SigC::bind<bool>(SigC::slot(this, &FormToc::updateSlot),false));
       b_close->clicked.connect(dialog_->destroy.slot());
-      dialog_->destroy.connect(slot(this, &FormToc::free));
+      dialog_->destroy.connect(SigC::slot(this, &FormToc::free));
 
-      u_ = d_->updateBufferDependent.connect(slot(this, &FormToc::updateSlot));
-      h_ = d_->hideBufferDependent.connect(slot(this, &FormToc::hide));
+      u_ = d_->updateBufferDependent.connect(SigC::slot(this, &FormToc::updateSlot));
+      h_ = d_->hideBufferDependent.connect(SigC::slot(this, &FormToc::hide));
 
       if (!dialog_->is_visible()) dialog_->show_all();
 
index b0a2ee1fa7d25e0bf2c92512a89c29ddc80c876c..4dbebc6471e215f0e33f710bb6e773cc7ed457b0 100644 (file)
@@ -36,9 +36,6 @@
 
 #include <gtk--/menu.h>
 
-using SigC::slot;
-using SigC::bind;
-
 using std::endl;
 
 // temporary solution for LyXView
@@ -66,7 +63,7 @@ Menubar::Pimpl::~Pimpl()
 void Menubar::Pimpl::set(string const & menu_name) 
 {
   // if (current_menu_name_ != menu_name)  // disabled until Lastfiles and Documents are added dynamically to menu
-    {
+       //{
       current_menu_name_ = menu_name;
 
       // clean up the lists
@@ -90,7 +87,7 @@ void Menubar::Pimpl::set(string const & menu_name)
       // update state of the items
       update();
       updateAllLists();
-    }
+      //}
 }
 
 void Menubar::Pimpl::updateAllLists()
@@ -104,6 +101,7 @@ void Menubar::Pimpl::updateAllLists()
 }
 
 int const max_number_of_items = 25;
+
 void Menubar::Pimpl::updateList(vector<Buffer::TocItem> * toclist, vector<ListsHolder> * pgui) 
 {
   vector<ListsHolder> & gui = *pgui;
@@ -116,7 +114,7 @@ void Menubar::Pimpl::updateList(vector<Buffer::TocItem> * toclist, vector<ListsH
       string label;
 
       menu.push_back(Gnome::UI::Item(Gnome::UI::Icon(GNOME_STOCK_MENU_REFRESH),
-                                    _("Refresh"), slot(this, &Menubar::Pimpl::updateAllLists)));
+                                    _("Refresh"), SigC::slot(this, &Menubar::Pimpl::updateAllLists)));
 
       if (toclist->size() > max_number_of_items)
        composeTocUIInfo(menu, *toclist, toclist->begin(), 0);
@@ -130,7 +128,7 @@ void Menubar::Pimpl::updateList(vector<Buffer::TocItem> * toclist, vector<ListsH
              label = string(4*(*it).depth,' ')+(*it).str;
              
              menu.push_back(Gnome::UI::Item(label,
-                                            bind<Buffer::TocItem>(slot(this, &Menubar::Pimpl::callbackToc), (*it)),
+                                            SigC::bind<Buffer::TocItem>(SigC::slot(this, &Menubar::Pimpl::callbackToc), (*it)),
                                             label));
            }
        }
@@ -157,7 +155,7 @@ Menubar::Pimpl::composeTocUIInfo(vector<Gnome::UI::Info> & menu,
        {
          label = (*it).str;
          menu.push_back(Gnome::UI::Item(label,
-                                      bind<Buffer::TocItem>(slot(this, &Menubar::Pimpl::callbackToc), (*it)),
+                                      SigC::bind<Buffer::TocItem>(SigC::slot(this, &Menubar::Pimpl::callbackToc), (*it)),
                                         label));
        }
       else
@@ -167,7 +165,7 @@ Menubar::Pimpl::composeTocUIInfo(vector<Gnome::UI::Info> & menu,
            {
              label = (*it).str;
              submenu.push_back(Gnome::UI::Item(label,
-                                               bind<Buffer::TocItem>(slot(this, &Menubar::Pimpl::callbackToc), (*it)),
+                                               SigC::bind<Buffer::TocItem>(SigC::slot(this, &Menubar::Pimpl::callbackToc), (*it)),
                                                label));
              ++it;    
            }
@@ -233,7 +231,7 @@ void Menubar::Pimpl::composeUIInfo(string const & menu_name, vector<Gnome::UI::I
        LyXFunc::func_status flag = owner_->getLyXFunc()->getStatus(item.action());
 
        Gnome::UI::Info gitem;
-       SigC::Slot0<void> cback = bind<int>(slot(this, &Menubar::Pimpl::callback),item.action());
+       SigC::Slot0<void> cback = SigC::bind<int>(SigC::slot(this, &Menubar::Pimpl::callback),item.action());
 
        {
          using namespace Gnome::MenuItems;
index 2383f1cc417c5350c92ef7b62cc673ac8ec86602..694ce50c5207bf7c3f8a29787cb125144f91957d 100644 (file)
@@ -28,10 +28,6 @@ class MenuBackend;
 class MenuItem;
 class StrPool;
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Connection;
-#endif
-
 #include "debug.h"
 
 /*
@@ -107,7 +103,7 @@ private:
   vector<GtkWidgetToAction> wid_act_;
 
   /// toc
-  Connection utoc_;
+  SigC::Connection utoc_;
   vector<ListsHolder> toc_;
 };
 #endif
index 84b887bd93940dfd44f2692da52bdd5797db23a4..befcf445c2de061897d27fdac8bae6ff5e4e721d 100644 (file)
@@ -1,3 +1,7 @@
+2001-03-15  Lars Gullik Bjønnes  <larsbj@trylle.birdstep.com>
+
+       * several files: remove CXX_WORKING_NAMESPACES
+
 2001-03-14  Angus Leeming  <a.leeming@ic.ac.uk>
 
        * Merging changes from BRANCH_MVC back into HEAD.
index 8e49a249b2621ffb3f6365d7b643e159815ebb65..f69367ab316458fc41c2d7a6e75768743c03cbc8 100644 (file)
@@ -20,9 +20,7 @@
 #include "QtLyXView.h"
 #include "debug.h"
 
-#ifdef CXX_WORKING_NAMESPACES
 using Liason::setMinibuffer;
-#endif
 
 FormDocument::FormDocument(LyXView *v, Dialogs *d)
        : dialog_(0), lv_(v), d_(d), h_(0)
index 12ae601390b64d7d4b51ef5468d475c83ff5b529..c74124b3ca730bfada887197dfbb9dd622e2623d 100644 (file)
 #include "lyxtext.h"
 #include "debug.h"
 
-#ifdef CXX_WORKING_NAMESPACES
 using Liason::setMinibuffer;
-#endif
-
 using std::endl;
 
 FormParagraph::FormParagraph(LyXView *v, Dialogs *d)
index 852b107e866f11b1d6f98f30a0b24ff1db64fc52..e076d42862a79d1c141a06eff07fa5d71bf0c740 100644 (file)
 
 #include <kmsgbox.h>
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::slot;
-#endif
-
-#ifdef CXX_WORKING_NAMESPACES
 using Liason::printBuffer;
 using Liason::getPrinterParams;
 using std::max;
-#endif
 
 FormPrint::FormPrint(LyXView *v, Dialogs *d)
        : dialog_(0), lv_(v), d_(d), h_(0), u_(0)
 {
-       d->showPrint.connect(slot(this, &FormPrint::show));
+       d->showPrint.connect(SigC::slot(this, &FormPrint::show));
 }
 
 
@@ -88,8 +82,7 @@ void FormPrint::print()
                        to = strToInt(dialog_->getTo());
        }
        
-       int retval; 
-       retval = printBuffer(lv_->buffer(), PrinterParams(dialog_->getTarget(),
+       int retval = printBuffer(lv_->buffer(), PrinterParams(dialog_->getTarget(),
                string(dialog_->getPrinter()), string(dialog_->getFile()), 
                dialog_->getWhichPages(), from, to, dialog_->getReverse(), 
                dialog_->getSort(), max(strToInt(dialog_->getCount()),1)));
@@ -112,8 +105,8 @@ void FormPrint::show()
                dialog_ = new PrintDialog(this, 0, _("LyX: Print"));
  
        if (!dialog_->isVisible()) {
-               h_ = d_->hideBufferDependent.connect(slot(this, &FormPrint::hide));
-               u_ = d_->updateBufferDependent.connect(slot(this, &FormPrint::update));
+               h_ = d_->hideBufferDependent.connect(SigC::slot(this, &FormPrint::hide));
+               u_ = d_->updateBufferDependent.connect(SigC::slot(this, &FormPrint::update));
        }
 
        dialog_->raise();
index b27e9518e045210f235b356ced77fca95f34f50e..0ffb2cda12337cb14826c8009308acbecbd36b76 100644 (file)
@@ -1,3 +1,4 @@
+// -*- C++ -*-
 /**
  * \file FormPrint.h
  * Copyright 2001 the LyX Team
@@ -16,14 +17,12 @@ class Dialogs;
 class LyXView;
 class PrintDialog;
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Connection;
-#endif
-
+///
 class FormPrint : public DialogBase {
-public: 
+public:
+        ///
        FormPrint(LyXView *, Dialogs *);
-
+       ///
        ~FormPrint();
 
        /// start print
@@ -51,9 +50,9 @@ private:
        Dialogs * d_;
        
        /// Hide connection.
-       Connection h_;
+       SigC::Connection h_;
        /// Update connection.
-       Connection u_;
+       SigC::Connection u_;
 };
 
 #endif // FORMPRINT_H
index bd24363d62222df5a5323fb072165d2558f9989c..4a8826aa7cd22edb5182bf492850df9ca4a2b16a 100644 (file)
@@ -11,9 +11,7 @@
 #include "dlg/helpers.h"
 #include "citationdlg.h"
 
-#ifdef CXX_WORKING_NAMESPACES
 using kde_helpers::setSizeHint;
-#endif
 
 CitationDialog::CitationDialog(FormCitation *form, QWidget *parent, char const * name, bool, WFlags)
        : QDialog(parent,name,0), form_(form)
index 4358850c92746c518f16a60e2bec45a870c0ddb2..5cb2526516f3f37bd46a532341991a5b260670ca 100644 (file)
@@ -19,9 +19,7 @@
 
 using std::endl;
 
-#ifdef CXX_WORKING_NAMESPACES
 namespace kde_helpers {
-#endif
 
 bool setComboFromStr(QComboBox *box, const string & str)
 {
@@ -35,6 +33,4 @@ bool setComboFromStr(QComboBox *box, const string & str)
        return false;
 }
 
-#ifdef CXX_WORKING_NAMESPACES
-}; /* namespace kde_helpers */
-#endif
+} // namespace kde_helpers
index 89db077bfe8b1767e6a6007d9a7c3d9822297ee3..7f3768d7678405301d99a08f8ec991ef9cfb43aa 100644 (file)
@@ -16,9 +16,7 @@
 
 #include "vspace.h"
 
-#ifdef CXX_WORKING_NAMESPACES
 namespace kde_helpers {
-#endif
  
 /**
  * \fn setSizeHint
@@ -43,8 +41,6 @@ inline void setSizeHint(QWidget *widget)
  */
 bool setComboFromStr(QComboBox *box, const string & str);
 
-#ifdef CXX_WORKING_NAMESPACES
-}; /* namespace kde_helpers */
-#endif
+} // namespace kde_helpers
 
 #endif /* HELPERS_H */
index 21e7169b8ac8908434bed2aba0328234ca49ea85..d6d32f29be0c2fccf62b4e90138c84736a6cfa28 100644 (file)
 #include "gettext.h"
 #include "debug.h"
 
-#ifdef CXX_WORKING_NAMESPACES
 using kde_helpers::setSizeHint;
 using kde_helpers::setComboFromStr;
-#endif
-
 using std::endl;
 
 DocDialog::DocDialog(FormDocument * form, QWidget * parent, char const * name, bool, WFlags)
index f00dab3a71f60adf15613ca84eea7e3dca5bbcaf..cf994ecf904bcaf03a079938c259384a724e95ec 100644 (file)
 #include "gettext.h"
 #include "debug.h"
 
-#ifdef CXX_WORKING_NAMESPACES
 using kde_helpers::setSizeHint;
-#endif
-
 using std::endl;
 
 ParaDialog::ParaDialog(FormParagraph * form, QWidget * parent, char const * name, bool, WFlags)
index f5e75515da11665a3979081696c8507cfc3a033e..0b518474737e8694a03f5ed752bbfb797e89b1b5 100644 (file)
@@ -15,9 +15,7 @@
 
 #include <gettext.h>
 
-#ifdef CXX_WORKING_NAMESPACES
 using kde_helpers::setSizeHint;
-#endif
 
 ParaExtraDialog::ParaExtraDialog (QWidget * parent, char const * name) 
        : ParaExtraDialogData(parent, name)
index 06d36daed887de15ec8fa8ecb065d461979d0f65..f08452151d65b8b49684bff533212302e964ef0d 100644 (file)
@@ -15,9 +15,7 @@
 
 #include <qtooltip.h>
 
-#ifdef CXX_WORKING_NAMESPACES
 using kde_helpers::setSizeHint;
-#endif
 
 ParaGeneralDialog::ParaGeneralDialog (QWidget * parent, char const * name)
        : ParaGeneralDialogData(parent, name)
index fbd8097faa9bb67b3e420845956f24acd3674aee..140d0e58ed183efe2db0876f070187c45d32a9a5 100644 (file)
@@ -12,9 +12,7 @@
 #include "dlg/helpers.h"
 #include "insets/insetref.h"
 
-#ifdef CXX_WORKING_NAMESPACES
 using kde_helpers::setSizeHint;
-#endif
 
 RefDialog::RefDialog(FormRef * form, QWidget * parent, char const * name, bool, WFlags)
        : QDialog(parent,name,0), form_(form)
index d5f5e5e8ef55912ba6687630898644b942d20390..cb8183ad28939c9ce860755de45154512248541e 100644 (file)
@@ -11,9 +11,7 @@
 
 #include "dlg/helpers.h"
 
-#ifdef CXX_WORKING_NAMESPACES
 using kde_helpers::setSizeHint;
-#endif
 
 TocDialog::TocDialog(FormToc * form, QWidget * parent, char const * name, bool, WFlags)
        : QDialog(parent,name,0), form_(form)
index d25b4271af68f0d625e0409fb4ab7ccbe192e2c3..b9c22ffeceb480cd0b453976188b4baa969c4d8b 100644 (file)
@@ -11,9 +11,7 @@
 
 #include "dlg/helpers.h"
 
-#ifdef CXX_WORKING_NAMESPACES
 using kde_helpers::setSizeHint;
-#endif
 
 UrlDialog::UrlDialog(FormUrl *form, QWidget *parent, char const * name, bool, WFlags)
        : QDialog(parent,name,0), form_(form)
index ae3dc10eec254a64bbc418df9bb5b413aead9ec2..797cf390a626cfcc582dd7cc9f7853323c8463eb 100644 (file)
@@ -1,3 +1,7 @@
+2001-03-15  Lars Gullik Bjønnes  <larsbj@trylle.birdstep.com>
+
+       * several files: remove CXX_WORKING_NAMESPACES
+
 2001-03-15  Edwin Leuven  <leuven@fee.uva.nl>
 
        * Added splash screen
index 716acfcbc403701b8e4b552075adefa98f9e560a..2119d7fafe2f39f379687baf8571fd55c7b0ac4a 100644 (file)
@@ -19,9 +19,7 @@
 #include "language.h"
 #include "support/lstrings.h"
 
-#ifdef CXX_WORKING_NAMESPACES
 using Liason::setMinibuffer;
-#endif
 
 FormCharacter::FormCharacter(LyXView *v, Dialogs *d)
        : dialog_(0), lv_(v), d_(d), h_(0), u_(0)
index e42633d4f8c936283f7124a09cd71066975165ac..9995d167cc58def44d05a7a050630b5ea8b3780b 100644 (file)
 #include "lyxtext.h"
 #include "debug.h"
 
-#ifdef CXX_WORKING_NAMESPACES
 using Liason::setMinibuffer;
-#endif
-
 using std::endl;
 
 FormParagraph::FormParagraph(LyXView *v, Dialogs *d)
index 1e2ffa40fdf1db45d0146e118638818316a6347c..8dee1d43a11fcd062e19e14092efd47059d55ba3 100644 (file)
 #include "support/lstrings.h"
 #include "qmessagebox.h"
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::slot;
-#endif
-
-#ifdef CXX_WORKING_NAMESPACES
 using Liason::printBuffer;
 using Liason::getPrinterParams;
 using std::max;
-#endif
 
 FormPrint::FormPrint(LyXView *v, Dialogs *d)
        : dialog_(0), lv_(v), d_(d), h_(0), u_(0)
@@ -38,7 +32,7 @@ FormPrint::FormPrint(LyXView *v, Dialogs *d)
        // let the dialog be shown
        // This is a permanent connection so we won't bother
        // storing a copy because we won't be disconnecting.
-       d->showPrint.connect(slot(this, &FormPrint::show));
+       d->showPrint.connect(SigC::slot(this, &FormPrint::show));
 }
 
 FormPrint::~FormPrint()
@@ -88,8 +82,7 @@ void FormPrint::print()
                        to = strToInt(dialog_->getTo());
        }
        
-       int retval; 
-       retval = printBuffer(lv_->buffer(), PrinterParams(dialog_->getTarget(),
+       int retval = printBuffer(lv_->buffer(), PrinterParams(dialog_->getTarget(),
                string(dialog_->getPrinter()), string(dialog_->getFile()), 
                dialog_->getWhichPages(), from, to, dialog_->getReverse(), 
                dialog_->getSort(), max(strToInt(dialog_->getCount()),1)));
@@ -111,8 +104,8 @@ void FormPrint::show()
                dialog_ = new PrintDlgImpl(this, 0, _("LyX: Print"));
  
        if (!dialog_->isVisible()) {
-               h_ = d_->hideBufferDependent.connect(slot(this, &FormPrint::hide));
-               u_ = d_->updateBufferDependent.connect(slot(this, &FormPrint::update));
+               h_ = d_->hideBufferDependent.connect(SigC::slot(this, &FormPrint::hide));
+               u_ = d_->updateBufferDependent.connect(SigC::slot(this, &FormPrint::update));
        }
 
        dialog_->raise();
index 5af1912af6a1c9b431ea77c180a9265768d9fafe..786349fd7c227e3be0bd6d6833fba72fa19b9353 100644 (file)
@@ -15,10 +15,6 @@ class Dialogs;
 class LyXView;
 class PrintDlgImpl;
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Connection;
-#endif
-
 class FormPrint : public DialogBase {
 public: 
        /**@name Constructors and Destructors */
@@ -54,9 +50,9 @@ private:
        Dialogs * d_;
        
        /// Hide connection.
-       Connection h_;
+       SigC::Connection h_;
        /// Update connection.
-       Connection u_;
+       SigC::Connection u_;
 };
 
 #endif
index 5d9a3eba32d81464f777c8c3dc6a5657c7873610..98e1fbcd6b552e1332445ea82ba5eac8fd026489 100644 (file)
@@ -19,9 +19,7 @@
 //#include "language.h"
 #include "support/lstrings.h"
 
-#ifdef CXX_WORKING_NAMESPACES
 using Liason::setMinibuffer;
-#endif
 
 FormSearch::FormSearch(LyXView *v, Dialogs *d)
        : dialog_(0), lv_(v), d_(d), h_(0), u_(0)
@@ -29,7 +27,7 @@ FormSearch::FormSearch(LyXView *v, Dialogs *d)
    // let the popup be shown
    // This is a permanent connection so we won't bother
    // storing a copy because we won't be disconnecting.
-   d->showSearch.connect(slot(this, &FormSearch::show));
+   d->showSearch.connect(SigC::slot(this, &FormSearch::show));
    // perhaps in the future we'd like a
    // "search again" button/keybinding
 //    d->searchAgain.connect(slot(this, &FormSearch::FindNext));
@@ -48,8 +46,8 @@ void FormSearch::show()
    }
 
    if (!dialog_->isVisible()) {
-      h_ = d_->hideBufferDependent.connect(slot(this, &FormSearch::hide));
-      u_ = d_->updateBufferDependent.connect(slot(this, &FormSearch::update));
+      h_ = d_->hideBufferDependent.connect(SigC::slot(this, &FormSearch::hide));
+      u_ = d_->updateBufferDependent.connect(SigC::slot(this, &FormSearch::update));
    }
    
    dialog_->raise();
@@ -88,6 +86,8 @@ void FormSearch::replace(string const & searchstr, string const & replacestr,
       }
    }
 }
+
+
 void FormSearch::close()
 {
    h_.disconnect();
index eb7a1b504c7d8f6c35697c83b10906aa9874bf60..973d7f3a81958729d3c24a1edf790b4d94d07a79 100644 (file)
@@ -1,3 +1,7 @@
+2001-03-15  Lars Gullik Bjønnes  <larsbj@trylle.birdstep.com>
+
+       * several files: remove CXX_WORKING_NAMESPACES
+
 2001-03-14  Angus Leeming  <a.leeming@ic.ac.uk>
 
        * Merging changes from BRANCH_MVC back into HEAD.
index 4e218d7792b106ad5a4899f54cae3c114ad6681d..72181b7ded828120aed15c0314d3d78ec4456c4d 100644 (file)
@@ -50,7 +50,7 @@
 
 // Signal enabling all visible popups to be redrawn if so desired.
 // E.g., when the GUI colours have been remapped.
-Signal0<void> Dialogs::redrawGUI;
+SigC::Signal0<void> Dialogs::redrawGUI;
 
 Dialogs::Dialogs(LyXView * lv)
 {
index 6372a7683a804717824b00543554ce5297526905..cdb4a3c16df56210f52353bd1104080e068c149c 100644 (file)
@@ -109,9 +109,9 @@ protected: // methods
        /// Used so we can get at the signals we have to connect to.
        Dialogs * d_;
        /// Hide connection.
-       Connection h_;
+       SigC::Connection h_;
        /// Redraw connection.
-       Connection r_;
+       SigC::Connection r_;
        /// dialog title, displayed by WM.
        string title;
 public:
@@ -151,7 +151,7 @@ protected:
        virtual void updateSlot(bool) { update(); }
 
        /// Update connection.
-       Connection u_;
+       SigC::Connection u_;
 };
 
 
index 693c53f1be756c2cc35a53589ec6977b130e9339..7bd18e9ddf43168e958c2860480db58169d3826e 100644 (file)
 #include "lyxrc.h"
 #include "buffer.h"
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::slot;
-#endif
-
 FormBrowser::FormBrowser(LyXView * lv, Dialogs * d, const string & name)
        : FormBaseBD(lv, d, name)
 {}
index 234ed12f11cc36516878784fbeef8eb77748d5e7..cfe6bc5c3a6352f000744885b8e5ff0ab514ac56 100644 (file)
@@ -25,9 +25,7 @@
 #include "language.h"
 #include "combox.h"
 
-#ifdef CXX_WORKING_NAMESPACES
 using Liason::setMinibuffer;
-#endif
 
 
 FormCharacter::FormCharacter(LyXView * lv, Dialogs * d)
index b0eab6e6bd6bf7a8e0886b71c4cb55fec88fd29f..5634a1bee0db19f36a42294ff935bf3314616aa1 100644 (file)
@@ -40,9 +40,7 @@
 #include "bufferview_funcs.h"
 #include "xforms_helpers.h" 
 
-#ifdef CXX_WORKING_NAMESPACES
 using Liason::setMinibuffer;
-#endif
 
 #define USE_CLASS_COMBO 1
 
index 8e3e7762532ddd7cb7cf667f67775c54c81cfe9a..ca4b2e364fd8b5ed508b090c45f6eab7909899e1 100644 (file)
@@ -89,7 +89,7 @@ private:
        bool input(FL_OBJECT * obj, long data);
 
        /// inset::hide connection.
-       Connection ih_;
+       SigC::Connection ih_;
 
        /// build the dialog
        FD_form_external * build_external();
index c9a9700e5eaec5b95c60ed801a1b08f0005496b1..6aba39e629fdfc2268c69f0e1ebe8265d7c0a747 100644 (file)
@@ -71,10 +71,6 @@ extern "C" int gettimeofday(struct timeval *, struct timezone *);
 #include "support/filetools.h"
 #include "FormFiledialog.h"
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::slot;
-#endif
-
 // six months, in seconds
 static const long SIX_MONTH_SEC = 6L * 30L * 24L * 60L * 60L;
 static const long ONE_HOUR_SEC = 60L * 60L;
index 5d87dd0594fb24ea80f50e6b9f87c67c76f88e66..8ba1464a2434fb2820cee67336e3a56b597e8ef3 100644 (file)
@@ -1,3 +1,4 @@
+// -*- C++ -*-
 /**
  * \file FormFiledialog.h
  * Copyright 2001 the LyX Team
 
 #include "frontends/FileDialog.h"
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Object;
-using SigC::Connection;
-#endif
-
 /// DirEntry internal structure definition
 class DirEntry {
 public:
@@ -45,7 +41,7 @@ extern "C" void C_LyXFileDlg_FileDlgCB(FL_OBJECT * ob, long data);
 extern "C" void C_LyXFileDlg_DoubleClickCB(FL_OBJECT * ob, long data);
 extern "C" int C_LyXFileDlg_CancelCB(FL_FORM *fl, void *xev);
 
-class FileDialog::Private : public Object
+class FileDialog::Private : public SigC::Object
 {
 public:
        ///
@@ -128,7 +124,7 @@ private:
        /// Simulates a click on OK/Cancel
        void Force(bool);
        /// Redraw connection.
-       Connection r_;
+       SigC::Connection r_;
 };
 
 #endif // FORMFILEDIALOG_H
index cb046173b973875e37be839ef2d3339f44819303..f697ad994245b03feafb50cdbf322d9bcb9167ac 100644 (file)
@@ -74,7 +74,7 @@ private:
        ButtonController<OkCancelReadOnlyPolicy, xformsBC> bc_;
 
        /// inset::hide connection.
-       Connection ih_;
+       SigC::Connection ih_;
  
        /// pointer to the inset passed through showInset
        InsetInclude * inset_;
index 53946c6f49c5dc7c8f02ddbf376b7b8dee4667da..f9c489857278150f4d2d508c61328f22f7ad4a9d 100644 (file)
@@ -36,7 +36,7 @@ protected:
        virtual void updateSlot(bool);
 
        /// inset::hide connection.
-       Connection ih_;
+       SigC::Connection ih_;
 };
 
 
index dc74a12b0b89d37e13ce9519c824dc1c3840d2db..bbcc99b845dc3f10446e0e49abe02ea07c16466a 100644 (file)
 #include "lyxrc.h"
 #include "buffer.h"
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::slot;
-#endif
-
 FormLog::FormLog(LyXView * lv, Dialogs * d)
        : FormBrowser(lv, d, _("LaTeX Log"))
 {
index 0c28102a8a7581ae19b283175dc53a5061702c0f..682e25c2c924ebd214df4a10d3b5e3b1dec944d3 100644 (file)
@@ -26,9 +26,7 @@
 #include "lyxtext.h"
 #include "xforms_helpers.h"
 
-#ifdef CXX_WORKING_NAMESPACES
 using Liason::setMinibuffer;
-#endif
 
 FormParagraph::FormParagraph(LyXView * lv, Dialogs * d)
        : FormBaseBD(lv, d, _("Paragraph Layout"))
index af3746d99d0d41d5cd55ba07f43e70a8e1cb90d4..b82a6e2cea702f5db3077c21a198206245ef5e6d 100644 (file)
@@ -23,9 +23,7 @@
 #include "gettext.h"
 #include "xforms_helpers.h"
 
-#ifdef CXX_WORKING_NAMESPACES
 using Liason::setMinibuffer;
-#endif
 
 FormPreamble::FormPreamble(LyXView * lv, Dialogs * d)
        : FormBaseBD(lv, d, _("LaTeX preamble"))
index d9ad659b49d75cf58962d8ccecb90ab6220212a6..717bba95efb5c0996fa8f3af3cab7cefe86eaee7 100644 (file)
 #include "lyx_gui_misc.h"      // WriteAlert
 #include "xforms_helpers.h"     // for browseFile
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::slot;
-#endif
-
-#ifdef CXX_WORKING_NAMESPACES
 using Liason::printBuffer;
 using Liason::getPrinterParams;
-#endif
-
 using std::make_pair;
 
 FormPrint::FormPrint(LyXView * lv, Dialogs * d)
index 5f87c1c7d56e7f86afcd2333ab7ac2ffec2088b0..c9e86ad3a624e7c76084c5e0279991edcb3d89fb 100644 (file)
@@ -23,9 +23,7 @@
 #include "lyxfind.h"
 #include "debug.h"
 
-#ifdef CXX_WORKING_NAMESPACES
 using Liason::setMinibuffer;
-#endif
 
 
 FormSearch::FormSearch(LyXView * lv, Dialogs * d)
index 2579de3bf4157d215b736f900cc231f8f32d87b9..335d63d6cd4c5fce6b0bec46ce615ae135775692 100644 (file)
@@ -48,7 +48,7 @@ private:
        /// our container
        Dialogs * d_; 
        /// the show connection
-       Connection c_; 
+       SigC::Connection c_; 
 };
 
 #endif // FORMSPLASH_H
index 188cbeb76c7b2f1a841436f1f0faeea106d565e0..de7dead4aef4dc07356a852cbf7ca8a4651a3bcc 100644 (file)
 #include "lyxrc.h"
 #include "buffer.h"
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::slot;
-#endif
-
 FormVCLog::FormVCLog(LyXView * lv, Dialogs * d)
        : FormBrowser(lv, d, _("Version Control Log"))
 {
index 89f5eccfa62dfe120816ef73719e555789c200fa..3b5c04128dc00965c684c4ef7f16e89a538ec0fb 100644 (file)
 #include <boost/utility.hpp>
 #include <boost/smart_ptr.hpp>
 
-#include "sigc++/signal_system.h"
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Signal0;
-#endif
-
+#include <sigc++/signal_system.h>
 
 class LyXImage;
 
index f14c61a7a42a7d4abbaf459a481af2db31cb494a..832a11519193f8c0472cf371c53686085d3c95e3 100644 (file)
@@ -1,5 +1,7 @@
 2001-03-15  Lars Gullik Bjønnes  <larsbj@trylle.birdstep.com>
 
+       * several files: remvoe CXX_WORKING_NAMESPACES
+
        * ExternalTemplate.h: noncopyable is in namespace boost
        * insetinclude.h: ditto
        * insetcommand.h: ditto
index 2b8a109d49fbab980d514c3a14755576ec963082..b5c42789800864125e807c7b752ca87c2a317bd6 100644 (file)
 #include "converter.h"
 #include "frontends/Dialogs.h" // redrawGUI
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::slot;
-#endif
-
 using std::ostream;
 using std::istream;
 using std::ofstream;
@@ -955,7 +951,7 @@ InsetFig::InsetFig(int tmpx, int tmpy, Buffer const & o)
        raw_wid = raw_hgh = 0;
        changedfname = false;
        RegisterFigure(this);
-       r_ = Dialogs::redrawGUI.connect(slot(this, &InsetFig::redraw));
+       r_ = Dialogs::redrawGUI.connect(SigC::slot(this, &InsetFig::redraw));
 }
 
 
index 13d6a4f461438a64736993c67c13bdeec0ce8b2f..058d156e005e7737d516bb45af41df1d5ee5a64a 100644 (file)
 
 struct Figref;
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Object;
-using SigC::Connection;
-#endif
-
 ///
-class InsetFig: public Inset, public Object {
+class InsetFig: public Inset, public SigC::Object {
 public:
        ///
        InsetFig(int tmpx, int tmpy, Buffer const &);
@@ -156,7 +151,7 @@ private:
        /// get sizes from .eps file
        void GetPSSizes();
        /// Redraw connection.
-       Connection r_;
+       SigC::Connection r_;
 };
 
 
index d7225cda3ea40042ff03a5a43f0d28cddba5d661..cb0645420865dbeebd1fc408f2d99333d2fe77b0 100644 (file)
 #include <sigc++/signal_system.h>
 #include <boost/utility.hpp>
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Signal0;
-#endif
-
 // Created by Alejandro 970222
 /** Used to insert a LaTeX command automatically
  *
@@ -131,7 +127,7 @@ public:
        ///
        void setParams(InsetCommandParams const &);
        ///
-       Signal0<void> hideDialog;
+       SigC::Signal0<void> hideDialog;
 private:
        ///
        InsetCommandParams p_;
index 8233d2dbe61d132f8f47adf3adae0f982fca378d..82779294dddd234a2a16e691943eccf0c7367ef5 100644 (file)
 #include "LString.h"
 #include <sigc++/signal_system.h>
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Signal0;
-#endif
-
 /** Used for error messages from LaTeX runs.
   
   The edit-operation opens a 
@@ -73,8 +69,7 @@ public:
        ///
        string const & getContents() const { return contents; }
        ///
-       Signal0<void> hideDialog;
-
+       SigC::Signal0<void> hideDialog;
 private:
        ///
        string contents;
index 6639eacbbe4bb006dfc2809bad2b66ef1e409288..92fcf4e99970b564744d128fb5a1fd5aeee409dc 100644 (file)
 #include "support/path.h"
 #include "support/syscall.h"
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::slot;
-#endif
-
 using std::endl;
 
 InsetExternal::InsetExternal() 
index 278ad8a8275df008016364bc5d2573439034c01e..fdc870e6aaa4967d2a1150cb5b078e6e8d5860fa 100644 (file)
 #include "LString.h"
 #include <sigc++/signal_system.h>
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Signal0;
-#endif
-
 ///
 class InsetExternal : public InsetButton {
 public:
@@ -101,7 +97,7 @@ public:
        InsetExternalParams params() const;
 
        /// hide connection
-       Signal0<void> hideDialog;
+       SigC::Signal0<void> hideDialog;
 
 private:
        /// Write the output for a specific file format
index 5cb82a91deda5c69aa1cdf7a4c9bd69f8b1f5512..96df55fd29f9e6ec069cb18a5616c39f1b1c9b04 100644 (file)
 
 // We need a signal here to hide an active dialog when we are deleted.
 #include "sigc++/signal_system.h"
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Signal0;
-using SigC::slot;
-using SigC::Object;
-#endif 
 
 class Dialogs;
 class LyXImage;
 
 ///
-#ifdef SIGC_CXX_NAMESPACES
-class InsetGraphics : public Inset, public SigC::Object
-#else
-class InsetGraphics : public Inset, public Object
-#endif
-{
+class InsetGraphics : public Inset, public SigC::Object {
 public:
        ///
        InsetGraphics();
@@ -101,7 +91,7 @@ public:
        /** This signal is connected by our dialog and called when the inset
            is deleted.
        */
-       Signal0 <void> hideDialog;
+       SigC::Signal0<void> hideDialog;
 
 private:
        /// Update the inset after parameter change.
index 539cbe9d659013e231634d7f478c7fabcb688196..f4a0ef2a39c1b557383e523c00b0cb2788bb9b00 100644 (file)
@@ -106,7 +106,7 @@ public:
        bool loadIfNeeded() const;
  
        /// hide a dialog if about 
-       Signal0<void> hideDialog;
+       SigC::Signal0<void> hideDialog;
 private:
        /// get the text displayed on the button
        string const getScreenLabel() const;
index 58e77c0ec3df927c4213bc1d1f71d50374698cea..929ac624ed2a370708d9988a1d276ac8378da519 100644 (file)
 #include "lyxfunc.h"
 #include <sigc++/signal_system.h>
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Signal0;
-#endif
-
 class LyXLex;
 class Painter;
 class BufferView;
@@ -180,7 +176,7 @@ public:
     ///
     LyXTabular * tabular;
     ///
-    Signal0<void> hideDialog;
+    SigC::Signal0<void> hideDialog;
 
 private:
     ///
index 1dc2f5896381b2e4ee1d5fc700548c2cef293ef0..5b0c78e48aabd5c76b91d79ea9a83913a1f25bc8 100644 (file)
 #include "language.h"
 #include "frontends/Dialogs.h" // redrawGUI
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::slot;
-#endif
-
 using std::endl;
 
 // a wrapper around the callback static member.
index 0faf1a6712fc3fb5f7e2dad317d323c24a489665..1327dee213b5e6c48dae1b07b00bd4aeb884dc8e 100644 (file)
 class LyXText;
 class Combox;
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Object;
-using SigC::Connection;
-#endif
-
 /// default character set
 #define DEFCHSET "iso8859-1"
 
@@ -34,7 +29,7 @@ using SigC::Connection;
   classes. Probably should the gui class just have a pointer to the non
   gui class.
   */
-class Intl : public Object {
+class Intl : public SigC::Object {
 public:
        ///
        Intl();
@@ -101,7 +96,7 @@ private:
        ///
        TransManager trans;
        /// Redraw connection.
-       Connection r_;
+       SigC::Connection r_;
 };
 
 
index 8128a6b218371e6a24937910665adefe00eec398..2fb6a3b3c7cbc87124982195785cdbae726d7027 100644 (file)
 
 using std::endl;
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::slot;
-#endif
-
 extern bool keyseqUncomplete();
 extern string keyseqOptions(int l = 190);
 extern string keyseqStr(int l = 190);
index 2fa8b168c0c9ee137adcf6074fdff6d73221879e..23add6dbb4b15410f159d4fe5f3b8e1210511e2f 100644 (file)
 
 class LyXView;
 
-#ifdef SIGC_CXX_NAMESPACES
-using SigC::Object;
-#endif
-
 ///
-class MiniBuffer : public Object{
+class MiniBuffer : public SigC::Object {
 public:
        ///
        MiniBuffer(LyXView * o,
index 6cab81fbfd3869adee120169ebc3f242ea978d3f..b365c07c28f3fce9c40186759033d57aa7468bd8 100644 (file)
@@ -1,5 +1,7 @@
 2001-03-15  Lars Gullik Bjønnes  <larsbj@trylle.birdstep.com>
 
+       * several files: remove CXX_WORKING_NAMESPACES
+
        * FileInfo.h: noncopyable is in namespace boost
        * path.h: ditto
 
index 241dc31524ece2aee99b0f759cfb5d7270f4efc0..d121843cb4f761846ab1130669720efa3cffd0de 100644 (file)
@@ -3,18 +3,9 @@
 #include <sys/types.h>
 #include <signal.h>
 
-#ifdef CXX_WORKING_NAMESPACES
-namespace lyx {
-       int kill(int pid, int sig)
-       {
-               return ::kill(pid, sig);
-       }
-}
-#else
 #include "lyxlib.h"
 
 int lyx::kill(int pid, int sig)
 {
        return ::kill(pid, sig);
 }
-#endif
index d178797b05cd6c6b59cadfc85c8b6501279a8d95..4df4e58557e05910a54054cc2845f57eaab82384 100644 (file)
 // (an inlined member of some class)?
 
 // Use a namespace if we can, a struct otherwise
-#ifdef CXX_WORKING_NAMESPACES
-#define OPT_STATIC
 namespace lyx {
-#else
-#define OPT_STATIC static
-struct lyx {
-#endif 
-       ///
-       OPT_STATIC string const getcwd();
-        ///
-        OPT_STATIC int chdir(string const & name);
-        /// Returns false if it fails
-        OPT_STATIC bool rename(string const & from, string const & to);
-       /// Returns false it it fails
-       OPT_STATIC bool copy(string const & from, string const & to);
-       /// generates a checksum
-       OPT_STATIC unsigned long sum(string const & file);
-       /// returns a date string (not used currently)
-       OPT_STATIC char * date(); 
-       /// returns the name of the user (not used currently)
-       OPT_STATIC string const getUserName();
-       ///
-       OPT_STATIC int kill(int pid, int sig);
-       ///
-       OPT_STATIC void abort();
-        ///
-        OPT_STATIC int mkdir(string const & pathname, unsigned long int mode);
-       ///
-       OPT_STATIC int putenv(char const * str);
-        ///
-        OPT_STATIC int unlink(string const & file);
-        ///
-        OPT_STATIC int rmdir(string const & file);
-        ///
-        OPT_STATIC int atoi(string const & nstr);
-       ///
-       OPT_STATIC string const tempName(string const & dir = string(),
-                                        string const & mask = string());
-#ifdef CXX_WORKING_NAMESPACES
-}
-#else
-};
-#endif
 
-#undef OPT_STATIC
-       
+///
+string const getcwd();
+///
+int chdir(string const & name);
+/// Returns false if it fails
+bool rename(string const & from, string const & to);
+/// Returns false it it fails
+bool copy(string const & from, string const & to);
+/// generates a checksum
+unsigned long sum(string const & file);
+/// returns a date string (not used currently)
+char * date(); 
+/// returns the name of the user (not used currently)
+string const getUserName();
+///
+int kill(int pid, int sig);
+///
+void abort();
+///
+int mkdir(string const & pathname, unsigned long int mode);
+///
+int putenv(char const * str);
+///
+int unlink(string const & file);
+///
+int rmdir(string const & file);
+///
+int atoi(string const & nstr);
+///
+string const tempName(string const & dir = string(),
+                     string const & mask = string());
+
+} // namespace lyx
 #endif /* LYX_LIB_H */
index d4994099cc119ef0e4e8d5e71e45cc93a8955cb9..a54c0dff3bc8e1d1d630eac4894bfd2dd275ffdd 100644 (file)
@@ -2,18 +2,8 @@
 
 #include <stdlib.h>
 
-#ifdef CXX_WORKING_NAMESPACES
-namespace lyx {
-       int putenv(char const * str)
-       {
-               return ::putenv(const_cast<char*>(str));
-       }
-}
-#else
 #include "lyxlib.h"
 int lyx::putenv(char const * str)
 {
        return ::putenv(const_cast<char*>(str));
 }
-
-#endif
index 5a4d5d68fc444987f12becca97d4f4bdd8f8254e..2dc2e0d10c7d14ae28718d37375271584b6f013e 100644 (file)
@@ -39,11 +39,8 @@ the executable file might be covered by the GNU General Public License. */
 #include <iostream>
 #include <streambuf.h>
 
-#ifdef CXX_WORKING_NAMESPACES
 namespace std
 {
-#endif
-       
   class stringbuf : public streambuf
   {
   public:
@@ -169,9 +166,7 @@ namespace std
     { }
   };
 
-#ifdef CXX_WORKING_NAMESPACES
-}
-#endif
+} // namespace std
 
 inline int stringbuf::sync()
 {