]> git.lyx.org Git - lyx.git/blobdiff - src/bufferlist.C
I reactivate the code to resize the InsetText on a resize event of the main
[lyx.git] / src / bufferlist.C
index 060e6269fca6bfee6e6a6a887b6a2efc59bfc684..894f069449588ce2dca23c20a5c0fb7a3ec8f5df 100644 (file)
@@ -20,7 +20,6 @@
 
 #include "bufferlist.h"
 #include "lyx_main.h"
-#include "lyx_gui_misc.h"
 #include "lastfiles.h"
 #include "debug.h"
 #include "lyxrc.h"
@@ -32,6 +31,7 @@
 #include "LyXView.h"
 #include "vc-backend.h"
 #include "TextCache.h"
+#include "lyxtextclasslist.h"
 
 #include "frontends/Alert.h"
 
@@ -480,9 +480,11 @@ Buffer * BufferList::newFile(string const & name, string tname, bool isNamed)
                                   MakeDisplayPath(tname));
                        // no template, start with empty buffer
                        b->paragraph = new Paragraph;
+                       b->paragraph->layout(textclasslist[b->params.textclass].defaultLayoutName());
                }
        } else {  // start with empty buffer
                b->paragraph = new Paragraph;
+                       b->paragraph->layout(textclasslist[b->params.textclass].defaultLayoutName());
        }
 
        if (!lyxrc.new_ask_filename && !isNamed) {
@@ -542,7 +544,7 @@ Buffer * BufferList::loadLyXFile(string const & filename, bool tolastfiles)
                                // How can we know _how_ to do the checkout?
                                // With the current VC support it has to be,
                                // a RCS file since CVS do not have special ,v files.
-                               RCS::retrive(s);
+                               RCS::retrieve(s);
                                return loadLyXFile(filename, tolastfiles);
                        }
                }