]> git.lyx.org Git - lyx.git/blobdiff - src/format.C
Move #includes out of header files.
[lyx.git] / src / format.C
index 869bfb4d52ff02bf40a30f048cd054240236fcd6..d69d4ecb12a5a5d6fa19b2f06a89981db9fefa84 100644 (file)
@@ -150,7 +150,7 @@ void Formats::setViewer(string const & name, string const & command)
 }
 
 
-bool Formats::view(Buffer const * buffer, string const & filename,
+bool Formats::view(Buffer const & buffer, string const & filename,
                   string const & format_name) const
 {
        if (filename.empty())
@@ -174,12 +174,11 @@ bool Formats::view(Buffer const * buffer, string const & filename,
        if (format_name == "dvi" &&
            !lyxrc.view_dvi_paper_option.empty()) {
                command += ' ' + lyxrc.view_dvi_paper_option;
-               string paper_size = buffer->params.paperSizeName();
+               string paper_size = buffer.params.paperSizeName();
                if (paper_size == "letter")
                        paper_size = "us";
                command += ' ' + paper_size;
-               if (buffer->params.orientation
-                   == ORIENTATION_LANDSCAPE)
+               if (buffer.params.orientation == ORIENTATION_LANDSCAPE)
                        command += 'r';
        }
 
@@ -191,7 +190,7 @@ bool Formats::view(Buffer const * buffer, string const & filename,
        command = subst(command, token_path, QuoteName(OnlyPath(filename)));
 
        lyxerr[Debug::FILES] << "Executing command: " << command << std::endl;
-       buffer->message(_("Executing command: ") + command);
+       buffer.message(_("Executing command: ") + command);
 
        Path p(OnlyPath(filename));
        Systemcall one;