#include <klfmainwin.h>
Classes | |
struct | HelpLinkAction |
Public Slots | |
void | slotEvaluate () |
void | slotClear () |
void | slotClearLatex () |
void | slotClearAll () |
void | slotLibrary (bool showlib) |
void | slotLibraryButtonRefreshState (bool on) |
void | slotSymbols (bool showsymbs=true) |
void | slotSymbolsButtonRefreshState (bool on) |
void | slotExpandOrShrink () |
void | slotExpand (bool expanded=true) |
void | slotSetLatex (const QString &latex) |
void | slotSetMathMode (const QString &mathmode) |
void | slotSetPreamble (const QString &preamble) |
void | slotEnsurePreambleCmd (const QString &line) |
void | slotSetDPI (int DPI) |
void | slotSetFgColor (const QColor &fgcolor) |
void | slotSetFgColor (const QString &fgcolor) |
void | slotSetBgColor (const QColor &bgcolor) |
void | slotSetBgColor (const QString &bgcolor) |
void | slotEvaluateAndSave (const QString &output, const QString &format) |
bool | openFile (const QString &file) |
bool | openFiles (const QStringList &fileList) |
bool | openData (const QMimeData *mimeData, bool *openerFound=NULL) |
bool | openData (const QByteArray &data) |
bool | openLibFiles (const QStringList &files, bool showLibrary=true) |
bool | openLibFile (const QString &file, bool showLibrary=true) |
void | setApplicationLocale (const QString &locale) |
void | retranslateUi (bool alsoBaseUi=true) |
bool | loadDefaultStyle () |
bool | loadNamedStyle (const QString &sty) |
void | slotDrag () |
void | slotCopy () |
void | slotSave (const QString &suggestedFname=QString::null) |
void | slotSetExportProfile (const QString &exportProfile) |
void | slotActivateEditor () |
void | slotActivateEditorSelectAll () |
void | slotShowBigPreview () |
void | slotPresetDPISender () |
void | slotLoadStyle (int stylenum) |
void | slotLoadStyle (const KLFStyle &style) |
void | slotSaveStyle () |
void | slotStyleManager () |
void | slotSettings () |
void | refreshWindowSizes () |
void | refreshShowCorrectClearButton () |
void | refreshStylePopupMenus () |
void | loadStyles () |
void | loadLibrary () |
void | loadLibrarySavedState () |
void | saveStyles () |
void | restoreFromLibrary (const KLFLibEntry &entry, uint restoreflags) |
void | insertSymbol (const KLFLatexSymbol &symbol) |
void | insertDelimiter (const QString &delim, int charsBack=1) |
void | saveSettings () |
void | saveLibraryState () |
void | loadSettings () |
void | addWhatsNewText (const QString &htmlSnipplet) |
void | showAbout () |
void | showWhatsNew () |
void | showSettingsHelpLinkAction (const QUrl &link) |
void | helpLinkAction (const QUrl &link) |
void | setWidgetStyle (const QString &qtstyle) |
void | setTxtLatexFont (const QFont &f) |
void | setTxtPreambleFont (const QFont &f) |
void | showRealTimePreview (const QImage &preview, bool latexerror) |
void | updatePreviewBuilderThreadInput () |
void | displayError (const QString &errormsg) |
void | setWindowShownStatus (const QHash< QWidget *, bool > &windowshownflags) |
void | refreshAllWindowStyleSheets () |
void | setQuitOnClose (bool quitOnClose) |
void | quit () |
Signals | |
void | evaluateFinished (const KLFBackend::klfOutput &output) |
void | stylesChanged () |
void | applicationLocaleChanged (const QString &newLocale) |
Protected Member Functions | |
bool | try_load_style_list (const QString &fileName) |
void | showExportMsgLabel (const QString &msg, int timeout=3000) |
KLFBackend::klfInput | collectInput (bool isFinal) |
bool | event (QEvent *e) |
void | childEvent (QChildEvent *e) |
void | closeEvent (QCloseEvent *e) |
void | hideEvent (QHideEvent *e) |
void | showEvent (QShowEvent *e) |
void | timerEvent (QTimerEvent *e) |
void | getMissingCmdsFor (const QString &symbol, QStringList *missingCmds, QString *guiText, bool wantHtmlText=true) |
Properties | |
QString | widgetStyle |
KLatexFormula Main Window
Definition at line 218 of file klfmainwin.h.
Definition at line 245 of file klfmainwin.h.
KLFMainWin::KLFMainWin | ( | ) |
Definition at line 204 of file klfmainwin.cpp.
References _evaloutput_uptodate, _firstshow, _loadedlibrary, _output, _settings, _shrinkedsize, _styles, QMenu::addAction(), QGridLayout::addItem(), addWhatsNewText(), QGridLayout::addWidget(), KLFConfig::applicationFont, applicationLocaleChanged(), KLFConfig::checkExePaths(), collectInput(), KLFConfig::Core, KLFConfig::customMathModes, KLFConfig::enableRealTimePreview, KLFConfig::enableToolTipPreview, KLFBackend::klfOutput::errorstr, QFontInfo::family(), QWidget::fontInfo(), KLFConfig::glowEffect, KLFConfig::glowEffectColor, KLFConfig::glowEffectRadius, QSize::height(), helpLinkAction(), insertSymbol(), klfconfig, klfDbg, KLFConfig::labelOutputFixedSize, KLFConfig::latexEditFont, loadDefaultStyle(), loadLibrary(), loadSettings(), loadStyles(), mAboutDialog, mExportMsgLabel, mHelpLinkActions, mLatexSymbols, mLibBrowser, mPopup, mPreviewBuilderThread, mSettingsDialog, mStyleManager, mWhatsNewDialog, pExportMsgLabelTimerId, KLFConfig::preambleEditFont, quit(), refreshShowCorrectClearButton(), refreshStylePopupMenus(), refreshWindowSizes(), registerDataOpener(), restoreFromLibrary(), retranslateUi(), saveStyles(), QLabel::setAlignment(), QWidget::setAttribute(), QPalette::setColor(), QWidget::setFixedSize(), QFont::setPointSize(), QGridLayout::setSpacing(), showAbout(), showRealTimePreview(), slotActivateEditor(), slotActivateEditorSelectAll(), slotClearAll(), slotClearLatex(), slotCopy(), slotDrag(), slotEvaluate(), slotExpandOrShrink(), slotLibrary(), slotLoadStyle(), slotPresetDPISender(), slotSave(), slotSaveStyle(), slotSettings(), slotShowBigPreview(), slotSymbols(), QTimer::start(), QThread::start(), KLFBackend::klfOutput::status, stylesChanged(), KLFConfig::thisVersionMajMinFirstRun, u, KLFConfig::UI, updatePreviewBuilderThreadInput(), and QSize::width().
|
virtual |
Definition at line 494 of file klfmainwin.cpp.
References klfDbg, mLatexSymbols, mLibBrowser, mPreviewBuilderThread, mSettingsDialog, mStyleMenu, saveLibraryState(), saveSettings(), saveStyles(), and u.
|
slot |
Definition at line 1437 of file klfmainwin.cpp.
References KLFHelpDialogCommon::addExtraText(), and mWhatsNewDialog.
Referenced by KLFMainWin().
void KLFMainWin::alterSetting | ( | altersetting_which | which, |
int | ivalue | ||
) |
This function allows to temporarily modify a given setting with a new value. KLatexFormula will NOT remember the new setting in later executions.
Used eg. for command-line mode.
Note you have to use the correct function for each setting, if the setting requires an int use this function, if it requires a string use alterSetting(altersetting_which, QString).
Definition at line 1768 of file klfmainwin.cpp.
References _settings, _settings_altered, altersetting_BBorderOffset, altersetting_LBorderOffset, altersetting_OutlineFonts, altersetting_RBorderOffset, altersetting_TBorderOffset, KLFBackend::klfSettings::bborderoffset, KLFBackend::klfSettings::lborderoffset, KLFBackend::klfSettings::outlineFonts, KLFBackend::klfSettings::rborderoffset, and KLFBackend::klfSettings::tborderoffset.
Referenced by main(), KLFDBusAppAdaptor::setAlterSetting_i(), and KLFDBusAppAdaptor::setAlterSetting_s().
void KLFMainWin::alterSetting | ( | altersetting_which | which, |
QString | svalue | ||
) |
See alterSetting(altersetting_which, int)
Definition at line 1786 of file klfmainwin.cpp.
References _settings, _settings_altered, altersetting_Dvips, altersetting_Epstopdf, altersetting_Gs, altersetting_Latex, altersetting_TempDir, KLFBackend::klfSettings::dvipsexec, KLFBackend::klfSettings::epstopdfexec, KLFBackend::klfSettings::gsexec, KLFBackend::klfSettings::latexexec, and KLFBackend::klfSettings::tempdir.
|
signal |
Referenced by KLFMainWin(), and setApplicationLocale().
void KLFMainWin::applySettings | ( | const KLFBackend::klfSettings & | s | ) |
Definition at line 1823 of file klfmainwin.cpp.
References _settings, and _settings_altered.
Referenced by KLFSettings::apply().
|
inline |
Definition at line 234 of file klfmainwin.h.
bool KLFMainWin::canOpenData | ( | const QByteArray & | data | ) |
Definition at line 2200 of file klfmainwin.cpp.
References KLF_DEBUG_BLOCK, KLF_FUNC_NAME, klfDbg, pDataOpeners, QList::size(), and QByteArray::size().
Referenced by KLFLatexEdit::canInsertFromMimeData().
bool KLFMainWin::canOpenData | ( | const QMimeData * | mimeData | ) |
Definition at line 2211 of file klfmainwin.cpp.
References find_list_agreement(), QMimeData::formats(), QString::isEmpty(), KLF_DEBUG_BLOCK, KLF_FUNC_NAME, klfDbg, pDataOpeners, and QList::size().
bool KLFMainWin::canOpenFile | ( | const QString & | fileName | ) |
Definition at line 2189 of file klfmainwin.cpp.
References KLF_DEBUG_BLOCK, KLF_FUNC_NAME, klfDbg, pDataOpeners, and QList::size().
|
protected |
Definition at line 1541 of file klfmainwin.cpp.
References QList::append(), QChildEvent::child(), QList::indexOf(), QObject::isWidgetType(), klfDbg, pWindowList, and QList::removeAt().
|
protected |
Definition at line 2802 of file klfmainwin.cpp.
References _ignore_close_event, QWidget::hide(), and quit().
|
protected |
Returns the input corresponding to the current GUI state. If isFinal
is TRUE, then the input data may be "remembered" as used (the exact effect depends on the setting), eg. math mode is memorized into combo box choices. Typically isFinal
is TRUE when called from slotEvaluate() and FALSE when called to update the preview builder thread.
Definition at line 1865 of file klfmainwin.cpp.
References KLFBackend::klfInput::bg_color, KLFConfig::customMathModes, KLFBackend::klfInput::dpi, KLFBackend::klfInput::fg_color, klfconfig, KLFBackend::klfInput::latex, KLFBackend::klfInput::mathmode, KLFBackend::klfInput::preamble, u, and KLFConfig::UI.
Referenced by KLFMainWin(), saveSettings(), slotEvaluate(), and updatePreviewBuilderThreadInput().
|
inline |
Definition at line 243 of file klfmainwin.h.
|
inline |
Definition at line 239 of file klfmainwin.h.
Referenced by KLFSettings::apply(), and KLFSettings::reset().
KLFStyle KLFMainWin::currentStyle | ( | ) | const |
Definition at line 2672 of file klfmainwin.cpp.
References KLFStyle::bg_color, QColor::blue(), KLFStyle::BBoxExpand::bottom, KLFStyle::dpi, KLFStyle::fg_color, QColor::green(), KLFStyle::BBoxExpand::left, KLFStyle::mathmode, KLFStyle::name, KLFStyle::overrideBBoxExpand, KLFStyle::preamble, QColor::red(), KLFStyle::BBoxExpand::right, KLFStyle::BBoxExpand::top, and u.
Referenced by slotEvaluate(), and slotSaveStyle().
Definition at line 1675 of file klfmainwin.cpp.
References pWindowList, and QList::size().
Referenced by hideEvent().
|
slot |
Definition at line 1829 of file klfmainwin.cpp.
References QMessageBox::critical().
|
signal |
Referenced by slotEvaluate().
|
protected |
Definition at line 1528 of file klfmainwin.cpp.
References KLFConfig::applicationFont, QWidget::event(), QApplication::font(), klfconfig, klfDbg, QEvent::type(), KLFConfig::UI, and KLFConfig::useSystemAppFont.
Definition at line 1565 of file klfmainwin.cpp.
References QString::arg(), KLFConfig::copyExportProfile, KLFMimeExportProfile::description(), KLFConfig::dragExportProfile, KLFMimeExportProfile::findExportProfile(), QList::indexOf(), QObject::isWidgetType(), QKeyEvent::key(), klf_get_window_geometry(), klf_set_window_geometry(), klfconfig, QKeySequence::matches(), mLatexSymbols, mLibBrowser, mPopup, openFile(), pLastWindowGeometries, pLastWindowShownStatus, pWindowList, QToolTip::showText(), slotCopy(), slotEvaluate(), slotExpand(), slotLibraryButtonRefreshState(), slotSymbolsButtonRefreshState(), QEvent::type(), u, and KLFConfig::UI.
|
protected |
Definition at line 1149 of file klfmainwin.cpp.
References QString::arg(), QRegExp::cap(), QRegExp::exactMatch(), KLFLatexSymbolsCache::findSymbol(), QString::indexOf(), QString::isEmpty(), QStringList::join(), KLF_FUNC_NAME, klfDbg, QRegExp::pattern(), KLFLatexSymbol::preamble, QString::replace(), QStringList::replaceInStrings(), KLFLatexSymbolsCache::theCache(), u, and KLFLatexSymbol::valid().
|
slot |
Definition at line 1400 of file klfmainwin.cpp.
References QMetaObject::invokeMethod(), KLF_FUNC_NAME, klfDbg, mHelpLinkActions, QDesktopServices::openUrl(), QUrl::path(), QUrl::queryItems(), and QUrl::scheme().
Referenced by KLFMainWin().
|
protected |
Definition at line 1703 of file klfmainwin.cpp.
References currentWindowShownStatus(), QWidget::hideEvent(), klf_get_window_geometry(), pLastWindowGeometries, prepareAllWindowShownStatus(), pSavedWindowShownStatus, and setWindowShownStatus().
|
slot |
Inserts a delimiter delim
, and brings the cursor charsBack
characters back. Eg. you can insert "\mathrm{}"
and bring the cursor 1 space back.
Definition at line 1143 of file klfmainwin.cpp.
References u.
|
slot |
Definition at line 1118 of file klfmainwin.cpp.
References QWidget::activateWindow(), QTextCursor::beginEditBlock(), KLFLatexSymbol::preamble, slotEnsurePreambleCmd(), KLFLatexSymbol::symbol, and u.
Referenced by KLFMainWin().
|
inline |
Definition at line 277 of file klfmainwin.h.
References klfconfig.
KLFLatexEdit * KLFMainWin::latexEdit | ( | ) |
Definition at line 1806 of file klfmainwin.cpp.
References u.
|
inline |
Definition at line 269 of file klfmainwin.h.
|
inline |
Definition at line 268 of file klfmainwin.h.
|
slot |
Definition at line 580 of file klfmainwin.cpp.
References loadNamedStyle().
Referenced by KLFMainWin(), and slotClearAll().
|
slot |
Definition at line 838 of file klfmainwin.cpp.
References QUrl::addQueryItem(), KLFLibResourceEngine::allEntries(), KLFLibBrowser::ArchiveRoleFlag, KLFConfig::Core, KLFLibEngineFactory::createResource(), KLFLibResourceEngine::createSubResource(), QFile::exists(), KLFLibResourceEngine::FeatureSubResourceProps, KLFLibEngineFactory::findFactoryFor(), QUrl::fromLocalFile(), KLFLibBrowser::getOpenResource(), KLFLibBasicWidgetFactory::guessLocalFileScheme(), KLFLibResourceEngine::hasSubResource(), KLFLibBrowser::HistoryRoleFlag, KLFConfig::homeConfigDir, KLFLibResourceEngine::insertEntries(), QString::isEmpty(), kdelocate(), KLF_DEBUG_TIME_BLOCK, KLF_FUNC_NAME, klfconfig, klfDbg, KLFConfig::libraryFileName, KLFConfig::libraryLibScheme, loadLibrarySavedState(), mHistoryLibResource, mLibBrowser, KLFLibBrowser::NoCloseRoleFlag, KLFLibBrowser::OpenNoRaise, KLFLibBrowser::openResource(), KLFLibEngineFactory::openResource(), KLFLibEngineFactory::openURL(), QUrl::path(), QString::prepend(), QUrl::removeAllQueryItems(), QUrl::scheme(), KLFProgressDialog::setDescriptiveText(), QUrl::setScheme(), KLFLibResourceEngine::setSubResourceProperty(), KLFLibResourceEngine::setTitle(), KLFLibResourceEngine::setViewType(), QList::size(), KLFLibResourceEngine::subResourceList(), KLFLibResourceEngine::SubResPropViewType, and KLFLibResourceEngine::supportedFeatureFlags().
Referenced by KLFMainWin().
|
slot |
Definition at line 1013 of file klfmainwin.cpp.
References QDomDocument::documentElement(), QFile::exists(), QDomNode::firstChild(), KLFConfig::homeConfigDir, QDomNode::isNull(), KLF_FUNC_NAME, klfconfig, klfDbg, klfLoadVariantMapFromXML(), KLFConfig::LibraryBrowser, KLFLibBrowser::loadGuiState(), mLibBrowser, QDomNode::nextSibling(), QDomNode::nodeName(), QDomNode::nodeType(), QFile::open(), KLFConfig::restoreURLs, QDomDocument::setContent(), and QDomNode::toElement().
Referenced by loadLibrary().
|
slot |
Definition at line 590 of file klfmainwin.cpp.
References _styles, QList::size(), and slotLoadStyle().
Referenced by loadDefaultStyle().
|
slot |
Definition at line 602 of file klfmainwin.cpp.
References _settings, _settings_altered, KLFConfig::BackendSettings, KLFBackend::klfSettings::bborderoffset, KLFConfig::bborderoffset, KLFBackend::klfSettings::dvipsexec, KLFBackend::klfSettings::epstopdfexec, KLFConfig::execDvips, KLFBackend::klfSettings::execenv, KLFConfig::execenv, KLFConfig::execEpstopdf, KLFConfig::execGs, KLFConfig::execLatex, KLFBackend::klfSettings::gsexec, klfconfig, KLFBackend::klfSettings::latexexec, KLFBackend::klfSettings::lborderoffset, KLFConfig::lborderoffset, KLFBackend::klfSettings::outlineFonts, KLFConfig::outlineFonts, KLFBackend::klfSettings::rborderoffset, KLFConfig::rborderoffset, KLFBackend::klfSettings::tborderoffset, KLFConfig::tborderoffset, KLFBackend::klfSettings::tempdir, and KLFConfig::tempDir.
Referenced by KLFMainWin().
|
slot |
Definition at line 783 of file klfmainwin.cpp.
References _styles, QList::append(), QString::arg(), KLFConfig::homeConfigDir, QList::isEmpty(), kdelocate(), KLF_DATA_STREAM_APP_VERSION, klfconfig, mStyleMenu, refreshStylePopupMenus(), try_load_style_list(), and u.
Referenced by KLFMainWin().
|
slot |
Definition at line 2256 of file klfmainwin.cpp.
References QMimeData::data(), find_list_agreement(), QMimeData::formats(), QString::isEmpty(), KLF_DEBUG_TIME_BLOCK, KLF_FUNC_NAME, klfDbg, pDataOpeners, and QList::size().
Referenced by KLFLatexEdit::insertFromMimeData(), KLFDBusAppAdaptor::openData(), and openData().
|
slot |
Definition at line 2280 of file klfmainwin.cpp.
References KLF_DEBUG_TIME_BLOCK, KLF_FUNC_NAME, klfDbg, QByteArray::length(), openData(), pDataOpeners, and QList::size().
|
slot |
Definition at line 2229 of file klfmainwin.cpp.
References QMessageBox::critical(), KLF_DEBUG_TIME_BLOCK, KLF_FUNC_NAME, klfDbg, pDataOpeners, and QList::size().
Referenced by eventFilter(), KLFDBusAppAdaptor::openFile(), and openFiles().
|
slot |
Definition at line 2243 of file klfmainwin.cpp.
References KLF_DEBUG_TIME_BLOCK, KLF_FUNC_NAME, klfDbg, and openFile().
Referenced by KLFBasicDataOpener::openData(), and KLFDBusAppAdaptor::openFiles().
|
slot |
Definition at line 2308 of file klfmainwin.cpp.
References QUrl::addQueryItem(), QUrl::fromLocalFile(), KLFLibBasicWidgetFactory::guessLocalFileScheme(), QString::isEmpty(), KLF_DEBUG_TIME_BLOCK, KLF_FUNC_NAME, klfDbg, KLFLibEngineFactory::listSubResources(), mLibBrowser, KLFLibBrowser::openResource(), QUrl::setScheme(), and slotLibrary().
Referenced by KLFBasicDataOpener::openFile(), and openLibFiles().
|
slot |
Definition at line 2293 of file klfmainwin.cpp.
References KLF_DEBUG_TIME_BLOCK, KLF_FUNC_NAME, klfDbg, openLibFile(), and slotLibrary().
Referenced by KLFDBusAppAdaptor::importCmdlKLFFiles().
KLFLatexSyntaxHighlighter * KLFMainWin::preambleSyntaxHighlighter | ( | ) |
Definition at line 1814 of file klfmainwin.cpp.
References u.
QHash< QWidget *, bool > KLFMainWin::prepareAllWindowShownStatus | ( | bool | visibleStatus, |
bool | mainWindowToo = false |
||
) |
Definition at line 1685 of file klfmainwin.cpp.
References pWindowList, and QList::size().
Referenced by hideEvent().
|
slot |
Definition at line 1511 of file klfmainwin.cpp.
References QWidget::hide(), KLF_DEBUG_BLOCK, KLF_FUNC_NAME, mLatexSymbols, mLibBrowser, mSettingsDialog, and mStyleManager.
Referenced by closeEvent(), and KLFMainWin().
|
slot |
Definition at line 1665 of file klfmainwin.cpp.
References pWindowList, and QList::size().
Referenced by KLFSettings::apply().
|
slot |
Definition at line 572 of file klfmainwin.cpp.
References KLFConfig::clearLatexOnly, klfconfig, u, and KLFConfig::UI.
Referenced by KLFSettings::apply(), and KLFMainWin().
|
slot |
Definition at line 711 of file klfmainwin.cpp.
References _styles, QMenu::addAction(), QMenu::addSeparator(), QMenu::clear(), mStyleMenu, QAction::setData(), QList::size(), and slotStyleManager().
Referenced by KLFMainWin(), loadStyles(), retranslateUi(), and slotSaveStyle().
|
slot |
Definition at line 555 of file klfmainwin.cpp.
References _expandedsize, _shrinkedsize, QWidget::setFixedSize(), QSize::setHeight(), QSize::setWidth(), u, and QWidget::updateGeometry().
Referenced by KLFSettings::apply(), KLFMainWin(), and main().
void KLFMainWin::registerDataOpener | ( | KLFAbstractDataOpener * | dataopener | ) |
Definition at line 1462 of file klfmainwin.cpp.
References QList::append(), KLF_ASSERT_NOT_NULL, and pDataOpeners.
Referenced by KLFMainWin().
void KLFMainWin::registerHelpLinkAction | ( | const QString & | path, |
QObject * | object, | ||
const char * | member, | ||
bool | wantUrlParam | ||
) |
Definition at line 1443 of file klfmainwin.cpp.
References mHelpLinkActions.
void KLFMainWin::registerOutputSaver | ( | KLFAbstractOutputSaver * | outputsaver | ) |
Definition at line 1450 of file klfmainwin.cpp.
References QList::append(), KLF_ASSERT_NOT_NULL, and pOutputSavers.
|
slot |
Definition at line 1092 of file klfmainwin.cpp.
References QWidget::activateWindow(), KLFLibEntry::latexWithCategoryTagsComments(), KLFLibEntry::preview(), KLFLib::RestoreLatex, KLFLib::RestoreStyle, slotLoadStyle(), slotSetLatex(), QWidget::style(), KLFLibEntry::style(), and u.
Referenced by KLFMainWin().
|
slot |
Definition at line 482 of file klfmainwin.cpp.
References QString::fromUtf8(), refreshStylePopupMenus(), and u.
Referenced by KLFMainWin().
|
slot |
Definition at line 1053 of file klfmainwin.cpp.
References QDomDocument::createElement(), KLFConfig::homeConfigDir, klfconfig, klfSaveVariantMapToXML(), mLibBrowser, QFile::open(), KLFLibBrowser::saveGuiState(), and QDomDocument::toByteArray().
Referenced by ~KLFMainWin().
|
slot |
Definition at line 621 of file klfmainwin.cpp.
References _settings, _settings_altered, KLFConfig::BackendSettings, KLFBackend::klfSettings::bborderoffset, KLFConfig::bborderoffset, collectInput(), KLFConfig::colorChooseWidgetCustom, KLFConfig::colorChooseWidgetRecent, KLFColorChooser::colorList(), KLFConfig::copyExportProfile, KLFColorChooseWidget::customColors(), KLFConfig::dragExportProfile, KLFBackend::klfSettings::dvipsexec, KLFConfig::enableRealTimePreview, KLFConfig::enableToolTipPreview, KLFBackend::klfSettings::epstopdfexec, KLFConfig::execDvips, KLFBackend::klfSettings::execenv, KLFConfig::execenv, KLFConfig::execEpstopdf, KLFConfig::execGs, KLFConfig::execLatex, KLFConfig::glowEffect, KLFConfig::glowEffectColor, KLFConfig::glowEffectRadius, KLFBackend::klfSettings::gsexec, QSize::height(), QThread::isRunning(), klfconfig, klfDbg, KLFConfig::labelOutputFixedSize, KLFBackend::klfSettings::latexexec, KLFBackend::klfSettings::lborderoffset, KLFConfig::lborderoffset, KLFConfig::menuExportProfileAffectsCopy, KLFConfig::menuExportProfileAffectsDrag, mPreviewBuilderThread, KLFBackend::klfSettings::outlineFonts, KLFConfig::outlineFonts, pExportProfileQuickMenuActionList, KLFBackend::klfSettings::rborderoffset, KLFConfig::rborderoffset, KLFColorChooseWidget::recentColors(), KLFPreviewBuilderThread::settingsChanged(), QList::size(), QThread::start(), KLFBackend::klfSettings::tborderoffset, KLFConfig::tborderoffset, KLFBackend::klfSettings::tempdir, KLFConfig::tempDir, u, KLFConfig::UI, KLFConfig::userColorList, QSize::width(), and KLFConfig::writeToConfig().
Referenced by KLFSettings::apply(), slotSetExportProfile(), and ~KLFMainWin().
|
slot |
Definition at line 822 of file klfmainwin.cpp.
References _styles, QString::arg(), QMessageBox::critical(), KLFConfig::ensureHomeConfigDir(), KLFConfig::homeConfigDir, KLF_DATA_STREAM_APP_VERSION, klfconfig, klfDataStreamWriteHeader(), and QFile::open().
Referenced by KLFMainWin(), slotSaveStyle(), and ~KLFMainWin().
|
slot |
Definition at line 2341 of file klfmainwin.cpp.
References applicationLocaleChanged(), and klf_reload_translations().
Referenced by KLFSettings::apply().
|
slot |
Definition at line 1505 of file klfmainwin.cpp.
References _ignore_close_event.
|
inline |
Definition at line 271 of file klfmainwin.h.
Referenced by KLFAddOnDataOpener::openFile().
|
slot |
|
slot |
|
slot |
Definition at line 1474 of file klfmainwin.cpp.
References _widgetstyle, QStyleFactory::create(), QStringList::indexOf(), QString::isNull(), and QStyleFactory::keys().
Definition at line 1696 of file klfmainwin.cpp.
References QHash::begin(), QHash::end(), and QMetaObject::invokeMethod().
Referenced by hideEvent(), and showEvent().
|
slot |
Definition at line 1378 of file klfmainwin.cpp.
References mAboutDialog, and KLFAboutDialog::show().
Referenced by KLFMainWin().
|
protected |
Definition at line 1714 of file klfmainwin.cpp.
References _firstshow, QHash::contains(), KLFConfig::Core, QMetaObject::invokeMethod(), klf_set_window_geometry(), klfconfig, pLastWindowGeometries, pSavedWindowShownStatus, setWindowShownStatus(), QWidget::showEvent(), and KLFConfig::thisVersionMajMinFirstRun.
|
protected |
Definition at line 695 of file klfmainwin.cpp.
References mExportMsgLabel, and pExportMsgLabelTimerId.
Referenced by slotCopy().
|
slot |
Definition at line 1852 of file klfmainwin.cpp.
References _evaloutput_uptodate, klfDbg, QImage::size(), and u.
Referenced by KLFMainWin().
|
slot |
Definition at line 1393 of file klfmainwin.cpp.
References klfDbg, mSettingsDialog, QUrl::queryItemValue(), KLFSettings::show(), and KLFSettings::showControl().
|
slot |
Definition at line 1383 of file klfmainwin.cpp.
References QApplication::desktop(), QSize::height(), mWhatsNewDialog, KLFWhatsNewDialog::show(), and QSize::width().
|
slot |
Definition at line 2634 of file klfmainwin.cpp.
References QWidget::activateWindow(), and u.
Referenced by KLFMainWin(), and slotActivateEditorSelectAll().
|
slot |
Definition at line 2641 of file klfmainwin.cpp.
References slotActivateEditor(), and u.
Referenced by KLFMainWin().
|
inlineslot |
Definition at line 308 of file klfmainwin.h.
|
slot |
Definition at line 2041 of file klfmainwin.cpp.
References loadDefaultStyle(), and slotClearLatex().
Referenced by KLFMainWin().
|
slot |
Definition at line 2037 of file klfmainwin.cpp.
References u.
Referenced by KLFMainWin(), and slotClearAll().
|
slot |
Definition at line 2436 of file klfmainwin.cpp.
References _output, QApplication::clipboard(), KLFConfig::copyExportProfile, KLFMimeExporter::data(), KLFMimeExportProfile::description(), KLFMimeExportProfile::findExportProfile(), QString::isEmpty(), KLF_FUNC_NAME, klfconfig, KLFMimeExporter::mimeExporterLookup(), KLFMimeExportProfile::mimeTypes(), KLFMimeExportProfile::respectiveWinType(), showExportMsgLabel(), KLFConfig::UI, and QWidget::winId().
Referenced by eventFilter(), and KLFMainWin().
|
slot |
Definition at line 2388 of file klfmainwin.cpp.
References _output, QPainter::boundingRect(), KLFMimeExportProfile::description(), KLFConfig::dragExportProfile, QPainter::drawText(), QPainter::fillRect(), KLFMimeExportProfile::findExportProfile(), QPixmap::fromImage(), QImage::height(), QSize::height(), QPixmap::height(), QImage::isNull(), klfconfig, klfDbg, KLFBackend::klfOutput::result, QImage::scaled(), QDrag::setDragCursor(), QPainter::setFont(), QDrag::setHotSpot(), QDrag::setMimeData(), QPainter::setPen(), QFont::setPixelSize(), QDrag::setPixmap(), QPainter::setRenderHint(), QImage::size(), KLFConfig::UI, QImage::width(), QPixmap::width(), and QSize::width().
Referenced by KLFMainWin().
|
slot |
If line
is already in the preamble, then does nothing. Otherwise appends line
to the preamble text.
Definition at line 2107 of file klfmainwin.cpp.
References QTextCursor::beginEditBlock(), QTextCursor::endEditBlock(), QString::indexOf(), QTextCursor::insertText(), QString::length(), QTextCursor::movePosition(), and u.
Referenced by insertSymbol().
|
slot |
Definition at line 1892 of file klfmainwin.cpp.
References _evaloutput_uptodate, _output, _settings, KLFBackend::klfSettings::bborderoffset, KLFLibEntry::Category, KLFLibEntry::category(), collectInput(), QMessageBox::critical(), QDateTime::currentDateTime(), currentStyle(), KLFLibEntry::DateTime, KLFLibResourceEngine::defaultSubResource(), KLFBackend::klfOutput::errorstr, evaluateFinished(), KLFSettings::ExecutablePaths, KLFLibResourceEngine::FeatureSubResourceProps, KLFLibResourceEngine::FeatureSubResources, KLFLibResourceEngine::QueryResult::FillRawEntryList, QPixmap::fromImage(), KLFBackend::getLatexFormula(), QImage::height(), QSize::height(), KLFLibResourceEngine::insertEntry(), KLFLibResourceEngine::isReadOnly(), klfconfig, KLFERR_NODVIPSPROG, KLFERR_NOEPSTOPDFPROG, KLFERR_NOGSPROG, KLFERR_NOLATEXPROG, KLFConfig::labelOutputFixedSize, KLFBackend::klfInput::latex, KLFLibEntry::Latex, KLFLibEntry::latex(), KLFBackend::klfSettings::lborderoffset, KLFLibResourceEngine::Query::limit, KLFLibResourceEngine::locked(), KLFLibResourceEngine::Query::matchCondition, mHistoryLibResource, KLFLib::EntryMatchCondition::mkMatchAll(), mSettingsDialog, KLFLibResourceEngine::Query::orderDirection, KLFLibResourceEngine::Query::orderPropId, KLFConfig::previewTooltipMaxSize, KLFLibResourceEngine::query(), KLFBackend::klfSettings::rborderoffset, KLFBackend::klfOutput::result, QImage::scaled(), KLFLibResourceEngine::setLocked(), KLFLibResourceEngine::setSubResourceProperty(), KLFSettings::show(), KLFSettings::showControl(), KLFProgErr::showError(), QImage::size(), KLFLibResourceEngine::Query::skip, KLFBackend::klfOutput::status, KLFLibEntry::Style, KLFLibEntry::style(), KLFLibResourceEngine::subResourceProperty(), KLFLibResourceEngine::SubResPropLocked, KLFLibResourceEngine::supportedFeatureFlags(), KLFLibEntry::Tags, KLFLibEntry::tags(), KLFBackend::klfSettings::tborderoffset, QPixmap::toImage(), u, KLFConfig::UI, KLFLibResourceEngine::Query::wantedEntryProperties, QMessageBox::warning(), QImage::width(), and QSize::width().
Referenced by eventFilter(), KLFMainWin(), and slotEvaluateAndSave().
Definition at line 2157 of file klfmainwin.cpp.
References _output, QMessageBox::critical(), QString::isEmpty(), QImage::isNull(), KLFBackend::klfOutput::result, KLFBackend::saveOutputToFile(), slotEvaluate(), QString::trimmed(), and u.
Referenced by KLFDBusAppAdaptor::evaluateAndSave(), and main().
|
slot |
Definition at line 2081 of file klfmainwin.cpp.
References slotExpandOrShrink(), and u.
Referenced by eventFilter().
|
slot |
Definition at line 2067 of file klfmainwin.cpp.
References _expandedsize, _shrinkedsize, QWidget::setFixedSize(), and u.
Referenced by KLFMainWin(), and slotExpand().
|
slot |
Definition at line 2048 of file klfmainwin.cpp.
References QWidget::activateWindow(), klfDbg, mLibBrowser, QWidget::raise(), and QWidget::setShown().
Referenced by KLFMainWin(), openLibFile(), and openLibFiles().
|
slot |
|
slot |
Definition at line 2736 of file klfmainwin.cpp.
References _styles, and QList::size().
Referenced by KLFMainWin(), loadNamedStyle(), and restoreFromLibrary().
|
slot |
Definition at line 2711 of file klfmainwin.cpp.
References KLFStyle::bg_color, KLFStyle::BBoxExpand::bottom, KLFStyle::dpi, KLFStyle::fg_color, KLFStyle::BBoxExpand::left, KLFStyle::mathmode, KLFStyle::overrideBBoxExpand, KLFStyle::preamble, KLFStyle::BBoxExpand::right, QColor::setRgb(), QString::simplified(), slotSetPreamble(), KLFStyle::BBoxExpand::top, u, and KLFStyle::BBoxExpand::valid().
|
slot |
Definition at line 2663 of file klfmainwin.cpp.
References QAction::data(), and slotSetDPI().
Referenced by KLFMainWin().
|
slot |
Definition at line 2477 of file klfmainwin.cpp.
References _output, QFileInfo::absolutePath(), QMessageBox::addButton(), QString::arg(), QList::begin(), QMessageBox::clickedButton(), QMap::contains(), QMessageBox::critical(), QList::end(), QMessageBox::exec(), QFile::exists(), QFileDialog::getSaveFileName(), QStringList::indexOf(), QString::isEmpty(), QStringList::join(), KLF_FUNC_NAME, klfconfig, KLFConfig::lastSaveDir, pOutputSavers, KLFBackend::saveOutputToFile(), KLFAbstractOutputSaver::saveToFile(), QMessageBox::setDefaultButton(), QMessageBox::setEscapeButton(), QFileInfo::setFile(), QMessageBox::setWindowTitle(), QList::size(), QFileInfo::suffix(), QImageWriter::supportedImageFormats(), QString::toLower(), KLFConfig::UI, and QMessageBox::warning().
Referenced by KLFMainWin().
|
slot |
Definition at line 2743 of file klfmainwin.cpp.
References _styles, QList::append(), currentStyle(), QInputDialog::getText(), QString::isEmpty(), KLFStyle::name, QMessageBox::question(), refreshStylePopupMenus(), saveStyles(), QList::size(), stylesChanged(), and QString::trimmed().
Referenced by KLFMainWin().
|
slot |
Definition at line 2143 of file klfmainwin.cpp.
References u.
Referenced by main(), KLFDBusAppAdaptor::setInputData(), and slotSetBgColor().
|
slot |
Definition at line 2147 of file klfmainwin.cpp.
References QColor::setNamedColor(), QColor::setRgb(), and slotSetBgColor().
|
slot |
Definition at line 2128 of file klfmainwin.cpp.
References u.
Referenced by main(), KLFDBusAppAdaptor::setInputData(), and slotPresetDPISender().
|
slot |
Definition at line 2348 of file klfmainwin.cpp.
References KLFConfig::copyExportProfile, KLFConfig::dragExportProfile, klfconfig, KLFConfig::menuExportProfileAffectsCopy, KLFConfig::menuExportProfileAffectsDrag, saveSettings(), and KLFConfig::UI.
Referenced by startupFinished().
|
slot |
Definition at line 2133 of file klfmainwin.cpp.
References u.
Referenced by main(), KLFDBusAppAdaptor::setInputData(), and slotSetFgColor().
|
slot |
Definition at line 2137 of file klfmainwin.cpp.
References QColor::setNamedColor(), and slotSetFgColor().
|
slot |
Definition at line 2090 of file klfmainwin.cpp.
References u.
Referenced by main(), restoreFromLibrary(), and KLFDBusAppAdaptor::setInputData().
|
slot |
Definition at line 2095 of file klfmainwin.cpp.
References QString::simplified(), and u.
Referenced by main(), and KLFDBusAppAdaptor::setInputData().
|
slot |
Definition at line 2102 of file klfmainwin.cpp.
References u.
Referenced by main(), KLFDBusAppAdaptor::setInputData(), and slotLoadStyle().
|
slot |
Definition at line 2796 of file klfmainwin.cpp.
References mSettingsDialog, and KLFSettings::show().
Referenced by KLFMainWin().
|
slot |
Definition at line 2647 of file klfmainwin.cpp.
References QString::arg(), QWhatsThis::showText(), and u.
Referenced by KLFMainWin().
|
slot |
Definition at line 2790 of file klfmainwin.cpp.
References mStyleManager, and QWidget::show().
Referenced by refreshStylePopupMenus().
|
slot |
Definition at line 2059 of file klfmainwin.cpp.
References QWidget::activateWindow(), mLatexSymbols, QWidget::raise(), QWidget::setShown(), and slotSymbolsButtonRefreshState().
Referenced by KLFMainWin().
|
slot |
Definition at line 1373 of file klfmainwin.cpp.
References u.
Referenced by eventFilter(), and slotSymbols().
void KLFMainWin::startupFinished | ( | ) |
called by main.cpp right after show(), just before entering into event loop.
Definition at line 517 of file klfmainwin.cpp.
References QMenu::addAction(), QList::append(), QList::clear(), KLFConfig::copyExportProfile, KLFConfig::dragExportProfile, KLFMimeExportProfile::exportProfileList(), klfconfig, pExportProfileQuickMenuActionList, QAction::setData(), QSignalMapper::setMapping(), QList::size(), slotSetExportProfile(), u, and KLFConfig::UI.
Referenced by main().
|
inline |
Definition at line 270 of file klfmainwin.h.
|
inline |
Definition at line 272 of file klfmainwin.h.
|
signal |
Referenced by KLFMainWin(), and slotSaveStyle().
KLFLatexSyntaxHighlighter * KLFMainWin::syntaxHighlighter | ( | ) |
Definition at line 1810 of file klfmainwin.cpp.
References u.
|
protected |
Definition at line 1736 of file klfmainwin.cpp.
References QColor::alpha(), QPalette::color(), mExportMsgLabel, pExportMsgLabelTimerId, QColor::setAlpha(), QPalette::setColor(), and QTimerEvent::timerId().
|
protected |
Definition at line 751 of file klfmainwin.cpp.
References _styles, QMessageBox::critical(), QFile::exists(), QString::isEmpty(), klfDataStreamReadHeader(), QFile::open(), and QMessageBox::warning().
Referenced by loadStyles().
|
virtual |
Definition at line 2694 of file klfmainwin.cpp.
References u.
|
virtual |
Definition at line 2698 of file klfmainwin.cpp.
References u.
void KLFMainWin::unregisterDataOpener | ( | KLFAbstractDataOpener * | dataopener | ) |
Definition at line 1468 of file klfmainwin.cpp.
References pDataOpeners, and QList::removeAll().
void KLFMainWin::unregisterOutputSaver | ( | KLFAbstractOutputSaver * | outputsaver | ) |
Definition at line 1457 of file klfmainwin.cpp.
References pOutputSavers, and QList::removeAll().
|
slot |
Definition at line 1835 of file klfmainwin.cpp.
References _evaloutput_uptodate, collectInput(), KLFPreviewBuilderThread::inputChanged(), and mPreviewBuilderThread.
Referenced by KLFMainWin().
|
inline |
Definition at line 282 of file klfmainwin.h.
|
protected |
If TRUE, then the output contained in _output is up-to-date, meaning that we favor displaying _output.result instead of the image given by mPreviewBuilderThread.
Definition at line 465 of file klfmainwin.h.
Referenced by KLFMainWin(), showRealTimePreview(), slotEvaluate(), and updatePreviewBuilderThreadInput().
|
protected |
Definition at line 482 of file klfmainwin.h.
Referenced by refreshWindowSizes(), and slotExpandOrShrink().
|
protected |
Definition at line 455 of file klfmainwin.h.
Referenced by KLFMainWin(), and showEvent().
|
protected |
Definition at line 494 of file klfmainwin.h.
Referenced by closeEvent(), and setQuitOnClose().
|
protected |
Definition at line 454 of file klfmainwin.h.
Referenced by KLFMainWin().
|
protected |
Definition at line 460 of file klfmainwin.h.
Referenced by KLFMainWin(), slotCopy(), slotDrag(), slotEvaluate(), slotEvaluateAndSave(), and slotSave().
|
protected |
Definition at line 457 of file klfmainwin.h.
Referenced by alterSetting(), applySettings(), KLFMainWin(), loadSettings(), saveSettings(), and slotEvaluate().
|
protected |
Definition at line 458 of file klfmainwin.h.
Referenced by alterSetting(), applySettings(), loadSettings(), and saveSettings().
|
protected |
Definition at line 481 of file klfmainwin.h.
Referenced by KLFMainWin(), refreshWindowSizes(), and slotExpandOrShrink().
|
protected |
Definition at line 448 of file klfmainwin.h.
Referenced by KLFMainWin(), loadNamedStyle(), loadStyles(), refreshStylePopupMenus(), saveStyles(), slotLoadStyle(), slotSaveStyle(), and try_load_style_list().
|
protected |
Definition at line 508 of file klfmainwin.h.
Referenced by setWidgetStyle().
|
protected |
Definition at line 430 of file klfmainwin.h.
Referenced by KLFMainWin(), and showAbout().
|
protected |
Definition at line 469 of file klfmainwin.h.
Referenced by KLFMainWin(), showExportMsgLabel(), and timerEvent().
|
protected |
Definition at line 444 of file klfmainwin.h.
Referenced by helpLinkAction(), KLFMainWin(), and registerHelpLinkAction().
|
protected |
Definition at line 446 of file klfmainwin.h.
Referenced by loadLibrary(), and slotEvaluate().
|
protected |
Definition at line 427 of file klfmainwin.h.
Referenced by eventFilter(), KLFMainWin(), quit(), slotSymbols(), and ~KLFMainWin().
|
protected |
Definition at line 426 of file klfmainwin.h.
Referenced by eventFilter(), KLFMainWin(), loadLibrary(), loadLibrarySavedState(), openLibFile(), quit(), saveLibraryState(), slotLibrary(), and ~KLFMainWin().
|
protected |
Definition at line 433 of file klfmainwin.h.
Referenced by eventFilter(), and KLFMainWin().
|
protected |
The Thread that will create real-time previews of formulas.
Definition at line 467 of file klfmainwin.h.
Referenced by KLFMainWin(), saveSettings(), updatePreviewBuilderThreadInput(), and ~KLFMainWin().
|
protected |
Definition at line 429 of file klfmainwin.h.
Referenced by KLFMainWin(), quit(), showSettingsHelpLinkAction(), slotEvaluate(), slotSettings(), and ~KLFMainWin().
|
protected |
Definition at line 428 of file klfmainwin.h.
Referenced by KLFMainWin(), quit(), and slotStyleManager().
|
protected |
Definition at line 452 of file klfmainwin.h.
Referenced by loadStyles(), refreshStylePopupMenus(), and ~KLFMainWin().
|
protected |
Definition at line 431 of file klfmainwin.h.
Referenced by addWhatsNewText(), KLFMainWin(), and showWhatsNew().
|
protected |
Definition at line 514 of file klfmainwin.h.
Referenced by canOpenData(), canOpenFile(), openData(), openFile(), registerDataOpener(), and unregisterDataOpener().
|
protected |
Definition at line 471 of file klfmainwin.h.
Referenced by KLFMainWin(), showExportMsgLabel(), and timerEvent().
Definition at line 479 of file klfmainwin.h.
Referenced by saveSettings(), and startupFinished().
Definition at line 500 of file klfmainwin.h.
Referenced by eventFilter(), hideEvent(), and showEvent().
"last" window status flags are used in eventFilter() to detect individual dialog geometries resetting
Definition at line 499 of file klfmainwin.h.
Referenced by eventFilter().
|
protected |
Definition at line 513 of file klfmainwin.h.
Referenced by registerOutputSaver(), slotSave(), and unregisterOutputSaver().
"saved" window status flags are used in hideEvent() to save the individual dialog visible states, as the "last" status flags will be overridden by all the windows hiding.
Definition at line 503 of file klfmainwin.h.
Referenced by hideEvent(), and showEvent().
Definition at line 496 of file klfmainwin.h.
Referenced by childEvent(), currentWindowShownStatus(), eventFilter(), prepareAllWindowShownStatus(), and refreshAllWindowStyleSheets().
|
protected |
Definition at line 424 of file klfmainwin.h.
Referenced by collectInput(), currentStyle(), eventFilter(), getMissingCmdsFor(), insertDelimiter(), insertSymbol(), KLFMainWin(), latexEdit(), loadStyles(), preambleSyntaxHighlighter(), refreshShowCorrectClearButton(), refreshWindowSizes(), restoreFromLibrary(), retranslateUi(), saveSettings(), setTxtLatexFont(), setTxtPreambleFont(), showRealTimePreview(), slotActivateEditor(), slotActivateEditorSelectAll(), slotClearLatex(), slotEnsurePreambleCmd(), slotEvaluate(), slotEvaluateAndSave(), slotExpand(), slotExpandOrShrink(), slotLibraryButtonRefreshState(), slotLoadStyle(), slotSetBgColor(), slotSetDPI(), slotSetFgColor(), slotSetLatex(), slotSetMathMode(), slotSetPreamble(), slotShowBigPreview(), slotSymbolsButtonRefreshState(), startupFinished(), syntaxHighlighter(), txtLatexFont(), txtPreambleFont(), and ~KLFMainWin().
|
readwrite |
Definition at line 221 of file klfmainwin.h.