]> git.lyx.org Git - lyx.git/blobdiff - src/insets/inseturl.h
clear()->erase() ; lots of using directives for cxx
[lyx.git] / src / insets / inseturl.h
index 5191ab088c5eec99037c832e5beef2d833604b7b..81ae62d3705f692a19d5c063a532e9d18b495bf9 100644 (file)
@@ -4,7 +4,7 @@
  *
  *           LyX, The Document Processor
  *      
- *         Copyright (C) 1997 LyX Team (this file was created this year)
+ *         Copyright 1997-2000 The LyX Team.
  * 
  * ====================================================== */
 
@@ -23,7 +23,7 @@ struct LaTeXFeatures;
 
 /** The url inset  
  */
-class InsetUrl: public InsetCommand {
+class InsetUrl : public InsetCommand {
 public:
         ///
         enum Url_Flags {
@@ -34,31 +34,33 @@ public:
        };
        
        ///
-       InsetUrl(): InsetCommand("url"), fd_form_url(0) {
+       InsetUrl() : InsetCommand("url"), fd_form_url(0) {
                flag = InsetUrl::URL;
        }
        ///
+       explicit
        InsetUrl(string const &);
        ///
+       explicit
        InsetUrl(InsetCommand const &);
        ///
        InsetUrl(string const &, string const &, string const &);
        ///
        ~InsetUrl();
         ///
-        InsetUrl * Clone() const { return new InsetUrl(getCommand()); }
+        Inset * Clone() const { return new InsetUrl(getCommand()); }
        ///
        Inset::Code LyxCode() const { return Inset::URL_CODE; }
        ///
        void Validate(LaTeXFeatures &) const;
        ///
-       void Edit(int, int);
+       void Edit(BufferView *, int, int, unsigned int);
        ///
-       unsigned char Editable() const {
-               return 1;
+       EDITABLE Editable() const {
+               return IS_EDITABLE;
        }
        ///
-       char const * EditMessage() {return "Opened Url";}
+       char const * EditMessage() const;
         ///
        bool display() const { return false; }
        ///
@@ -70,16 +72,24 @@ public:
         ///
         void gotoLabel();
        ///
-       int Latex(FILE * file, signed char fragile);
+       int Latex(std::ostream &, bool fragile, bool free_spc) const;
        ///
-       int Latex(string & file, signed char fragile);
+       int Ascii(std::ostream &) const;
        ///
-       int Linuxdoc(string & file);
+       int Linuxdoc(std::ostream &) const;
        ///
-       int DocBook(string & file);
+       int DocBook(std::ostream &) const;
        ///
        static void CloseUrlCB(FL_OBJECT *, long data);
 private:
+       ///
+       struct Holder {
+               InsetUrl * inset;
+               BufferView * view;
+       };
+       ///
+       Holder holder;
+       
        ///
         Url_Flags flag;
        ///