]> git.lyx.org Git - lyx.git/blobdiff - src/frontends/xforms/FormCharacter.h
Introduce LFUN_PRINT.
[lyx.git] / src / frontends / xforms / FormCharacter.h
index f19aa77c1fa4c8eabcef3fb8fc7dc5ca8c4a8520..080b61dc3928fe1a7ebc3bb5a7c906378f03140a 100644 (file)
@@ -1,72 +1,62 @@
 // -*- C++ -*-
-/** 
+/**
  * \file FormCharacter.h
- * Copyright 2001 The LyX Team.
- * See the file COPYING.
- * 
- * \author Edwin Leuven, leuven@fee.uva.nl
+ * This file is part of LyX, the document processor.
+ * Licence details can be found in the file COPYING.
+ *
+ * \author Edwin Leuven
+ * \author Angus Leeming
+ *
+ * Full author contact details are available in file CREDITS.
  */
 
 #ifndef FORM_CHARACTER_H
 #define FORM_CHARACTER_H
 
-#include <boost/smart_ptr.hpp>
+#include "FormDialogView.h"
+#include "ControlCharacter.h" // for ControlCharacter enum
 
-#include "FormBaseDeprecated.h"
-#include "xformsBC.h"
+struct LColor_color;
+struct FD_character;
 
-#ifdef __GNUG_
-#pragma interface
-#endif
-
-class LyXView;
-class Dialogs;
-class Combox;
-struct FD_form_character;
-
-/** 
- * This class provides an XForms implementation of the FormCharacter Dialog.
+/**
+ * This class provides an XForms implementation of the Character Dialog.
  * The character dialog allows users to change the character settings
  * in their documents.
  */
-class FormCharacter : public FormBaseBD {
+class FormCharacter
+       : public FormController<ControlCharacter, FormView<FD_character> > {
 public:
        ///
-       FormCharacter(LyXView *, Dialogs *);
+       FormCharacter(Dialog &);
 private:
-       
-       /// Pointer to the actual instantiation of the ButtonController.
-       virtual xformsBC & bc();
 
-       /// Build the popup
-       virtual void build();
-   
-       /// Apply from popup
+       /// Apply from dialog
        virtual void apply();
-   
-       /// Update the popup.
+
+       /// Build the dialog
+       virtual void build();
+
+       /// Update the dialog.
        virtual void update();
-   
-       /// Pointer to the actual instantiation of the xform's form
-       virtual FL_FORM * form() const;
 
-       ///
-       FD_form_character * build_character();
-       
-       /// Real GUI implementation.
-       boost::scoped_ptr<FD_form_character> dialog_;
+       /// Filter the inputs on callback from xforms
+       virtual ButtonPolicy::SMInput input(FL_OBJECT *, long);
 
        ///
-       boost::scoped_ptr<Combox> combo_language2_;
-
-       /// The ButtonController
-       ButtonController<NoRepeatedApplyReadOnlyPolicy, xformsBC> bc_;
+       std::vector<LyXFont::FONT_FAMILY>  family_;
+       ///
+       std::vector<LyXFont::FONT_SERIES>  series_;
+       ///
+       std::vector<LyXFont::FONT_SHAPE>   shape_;
+       ///
+       std::vector<LyXFont::FONT_SIZE>    size_;
+       ///
+       std::vector<frnt::FONT_STATE>      bar_;
+       ///
+       std::vector<LColor_color>            color_;
+       ///
+       std::vector<std::string>                lang_;
 };
 
-
-inline
-xformsBC & FormCharacter::bc()
-{
-       return bc_;
-}
 #endif