~ubuntu-branches/ubuntu/hardy/qgis/hardy

« back to all changes in this revision

Viewing changes to src/gui/qgsmapserverexport.h

  • Committer: Bazaar Package Importer
  • Author(s): William Grant
  • Date: 2007-05-06 13:42:32 UTC
  • mfrom: (1.1.2 upstream)
  • Revision ID: james.westby@ubuntu.com-20070506134232-pyli6t388w5asd8x
Tags: 0.8.0-3ubuntu1
* Merge from Debian unstable. Remaining Ubuntu changes:
  - debian/rules, debian/qgis.install, debian/qgis.dirs debian/qgis.desktop:
    Add and install .desktop.
* debian/qgis.desktop: Remove Applications category; it's not real.
* Modify Maintainer value to match Debian-Maintainer-Field Spec

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/***************************************************************************
 
2
    qgsmapserverexport.h - Export QGIS MapCanvas to MapServer
 
3
     --------------------------------------
 
4
    Date                 : 08-Nov-2003
 
5
    Copyright            : (C) 2003 by Gary E.Sherman
 
6
    email                : sherman at mrcc.com
 
7
 ***************************************************************************
 
8
 *                                                                         *
 
9
 *   This program is free software; you can redistribute it and/or modify  *
 
10
 *   it under the terms of the GNU General Public License as published by  *
 
11
 *   the Free Software Foundation; either version 2 of the License, or     *
 
12
 *   (at your option) any later version.                                   *
 
13
 *                                                                         *
 
14
 ***************************************************************************
 
15
 
 
16
  $Id: qgsmapserverexport.h 4688 2006-01-15 12:08:18Z telwertowski $ 
 
17
 
 
18
*/
 
19
 
 
20
#ifndef QGSMAPSERVEREXPORT_H
 
21
#define QGSMAPSERVEREXPORT_H
 
22
#include "ui_qgsmapserverexportbase.h"
 
23
#include "qgisgui.h"
 
24
class QgsMapCanvas;
 
25
 
 
26
/*! \class QgsMapServerExport
 
27
* \brief Class to handle reading and writing a Qgis project file
 
28
*/
 
29
class QgsMapserverExport:public QDialog, private Ui::QgsMapserverExportBase
 
30
{
 
31
Q_OBJECT
 
32
public:
 
33
  QgsMapserverExport(QgsMapCanvas *map=0, QWidget* parent = 0, 
 
34
        Qt::WFlags fl = QgisGui::ModalDialogFlags);
 
35
  ~QgsMapserverExport();
 
36
  //! Read the file and create the map
 
37
  bool read();
 
38
  //! Write the contents of the map to a file
 
39
  bool write();
 
40
  void setMapCanvas(QgsMapCanvas *map);
 
41
  //! Open a file dialog, the type determined by action (SAVE AS or OPEN)
 
42
  QString selectFileName();
 
43
  //! get the basename of the file (no path, just the file name)
 
44
  QString baseName();
 
45
  //! get the full path name of the map file
 
46
  QString fullPathName();
 
47
  //! Set the full path to the file
 
48
  void setFileName(QString filename);
 
49
  enum ACTION {
 
50
        SAVE,
 
51
        SAVEAS,
 
52
        OPEN
 
53
        };
 
54
public slots:
 
55
  void on_chkExpLayersOnly_clicked();
 
56
  void on_btnChooseFile_clicked();
 
57
  void on_buttonHelp_clicked();
 
58
private:
 
59
  void writeMapFile(void);
 
60
  QString fileName;
 
61
  QString fullPath;
 
62
  bool neverSaved;
 
63
  QgsMapCanvas *map;
 
64
  int action;
 
65
};
 
66
 
 
67
#endif //QGSMAPSERVEREXPORT_H
 
68