Back to index

texmacs  1.0.7.15
Public Member Functions | Protected Member Functions | Protected Attributes | Private Attributes
QTMImageDialog Class Reference

#include <QTMFileDialog.hpp>

Inheritance diagram for QTMImageDialog:
Inheritance graph
[legend]
Collaboration diagram for QTMImageDialog:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 QTMImageDialog (QWidget *parent=0, const QString &caption=QString(), const QString &directory=QString(), const QString &filter=QString())
string getParamsAsString ()
QStringList selectedFiles ()
void setViewMode (QFileDialog::ViewMode mode)
void setFileMode (QFileDialog::FileMode mode)
void setDefaultSuffix (const QString &suffix)
void setLabelText (QFileDialog::DialogLabel label, const QString &text)

Protected Member Functions

void dragEnterEvent (QDragEnterEvent *event)
void dragMoveEvent (QDragMoveEvent *event)
void dragLeaveEvent (QDragLeaveEvent *event)
void dropEvent (QDropEvent *event)

Protected Attributes

QHBoxLayout * hbox
QFileDialog * file

Private Attributes

QTMImagePreviewpreview

Detailed Description

Definition at line 77 of file QTMFileDialog.hpp.


Constructor & Destructor Documentation

QTMImageDialog::QTMImageDialog ( QWidget *  parent = 0,
const QString &  caption = QString (),
const QString &  directory = QString (),
const QString &  filter = QString () 
)

Definition at line 170 of file QTMFileDialog.cpp.

  : QTMFileDialog (parent, caption, directory, filter)
{
  preview= new QTMImagePreview (this);
  hbox->insertWidget(0, preview);
  connect(file, SIGNAL(currentChanged (const QString&)), preview, SLOT(setImage(const QString&)));
}

Here is the call graph for this function:


Member Function Documentation

void QTMFileDialog::dragEnterEvent ( QDragEnterEvent *  event) [protected, inherited]

Definition at line 43 of file QTMFileDialog.cpp.

{
       event->acceptProposedAction();
}
void QTMFileDialog::dragLeaveEvent ( QDragLeaveEvent *  event) [protected, inherited]

Definition at line 67 of file QTMFileDialog.cpp.

{
       event->accept();
}
void QTMFileDialog::dragMoveEvent ( QDragMoveEvent *  event) [protected, inherited]

Definition at line 48 of file QTMFileDialog.cpp.

{
       event->acceptProposedAction();
}
void QTMFileDialog::dropEvent ( QDropEvent *  event) [protected, inherited]

Definition at line 53 of file QTMFileDialog.cpp.

{
       const QMimeData *mimeData = event->mimeData();
       
       foreach (QString format, mimeData->formats()) {
              if (format == "text/uri-list") {
                     file->selectFile(mimeData->urls().at(0).toLocalFile());
                     break;
              }
       }
       
       event->acceptProposedAction();
}

Definition at line 179 of file QTMFileDialog.cpp.

                                   {
  string params;
  params << "\"" << from_qstring (preview->wid->text ()) << "\" ";
  params << "\"" << from_qstring (preview->hei->text ()) << "\" ";
  params << "\"" << from_qstring (preview->xps->text ()) << "\" ";
  params << "\"" << from_qstring (preview->yps->text ()) << "\"";
  return params;
}

Here is the call graph for this function:

Here is the caller graph for this function:

QStringList QTMFileDialog::selectedFiles ( ) [inline, inherited]

Definition at line 45 of file QTMFileDialog.hpp.

{ return file->selectedFiles (); };

Here is the caller graph for this function:

void QTMFileDialog::setDefaultSuffix ( const QString &  suffix) [inline, inherited]

Definition at line 54 of file QTMFileDialog.hpp.

{ return file->setDefaultSuffix (suffix);}

Here is the caller graph for this function:

void QTMFileDialog::setFileMode ( QFileDialog::FileMode  mode) [inline, inherited]

Definition at line 50 of file QTMFileDialog.hpp.

{ return file->setFileMode (mode); };

Here is the caller graph for this function:

void QTMFileDialog::setLabelText ( QFileDialog::DialogLabel  label,
const QString &  text 
) [inline, inherited]

Definition at line 55 of file QTMFileDialog.hpp.

{ return file->setLabelText (label, text); };

Here is the caller graph for this function:

void QTMFileDialog::setViewMode ( QFileDialog::ViewMode  mode) [inline, inherited]

Definition at line 49 of file QTMFileDialog.hpp.

{ return file->setViewMode (mode); };

Here is the caller graph for this function:


Member Data Documentation

QFileDialog* QTMFileDialog::file [protected, inherited]

Definition at line 36 of file QTMFileDialog.hpp.

QHBoxLayout* QTMFileDialog::hbox [protected, inherited]

Definition at line 35 of file QTMFileDialog.hpp.

Definition at line 81 of file QTMFileDialog.hpp.


The documentation for this class was generated from the following files: