KHTML
khtml_settings.cpp
Go to the documentation of this file.
162 kDebug(6000) << "Filter list loaded" << whiteCounter << "white list entries and" << blackCounter << "black list entries";
222 return static_cast<KJavaScriptAdvice>(KParts::HtmlSettingsInterface::textToJavascriptAdvice(_str));
227 return KParts::HtmlSettingsInterface::javascriptAdviceToText(static_cast<KParts::HtmlSettingsInterface::JavaScriptAdvice>(_advice));
402 bool filterEnabled = cgFilter.readEntry(QString("HTMLFilterListEnabled-").append(QString::number(id))) != QLatin1String("false");
409 QString localFile = cgFilter.readEntry(QString("HTMLFilterListLocalFilename-").append(QString::number(id)));
420 if (!fileInfo.exists() || fileInfo.lastModified().daysTo(QDateTime::currentDateTime()) > htmlFilterListMaxAgeDays)
443 d->defaultFonts.append( cgHtml.readEntry( "StandardFont", KGlobalSettings::generalFont().family() ) );
444 d->defaultFonts.append( cgHtml.readEntry( "FixedFont", KGlobalSettings::fixedFont().family() ) );
446 const QString serifFont = QFontInfo(QFont(QLatin1String(HTML_DEFAULT_VIEW_SERIF_FONT))).family();
447 const QString sansSerifFont = QFontInfo(QFont(QLatin1String(HTML_DEFAULT_VIEW_SANSSERIF_FONT))).family();
448 const QString cursiveFont = QFontInfo(QFont(QLatin1String(HTML_DEFAULT_VIEW_CURSIVE_FONT))).family();
449 const QString fantasyFont = QFontInfo(QFont(QLatin1String(HTML_DEFAULT_VIEW_FANTASY_FONT))).family();
549 const QStringList accesskeys = cgHtml.readEntry("FallbackAccessKeysAssignments", QStringList());
727 domainConfig.append(QString::fromLatin1("%1:%2:%3").arg(it.key()).arg(javaPolicy).arg(javaScriptPolicy));
740 domainConfig.append(QString::fromLatin1("%1:%2:%3").arg(it.key()).arg(javaPolicy).arg(javaScriptPolicy));
869 KConfigGroup config = KSharedConfig::openConfig( "khtmlrc", KConfig::NoGlobals )->group( "Filter Settings" );
void setPatternSyntax(PatternSyntax syntax)
QString i18n(const char *text)
QString sansSerifFontName() const
Definition: khtml_settings.cpp:1050
int indexOf(QChar ch, int from, Qt::CaseSensitivity cs) const
QList< QPair< QString, QChar > > fallbackAccessKeysAssignments() const
Definition: khtml_settings.cpp:1178
bool isFormCompletionEnabled() const
Definition: khtml_settings.cpp:1084
bool isJavaScriptDebugEnabled(const QString &hostname=QString()) const
Definition: khtml_settings.cpp:916
void setFixedFontName(const QString &n)
Definition: khtml_settings.cpp:1072
int maxFormCompletionItems() const
Definition: khtml_settings.cpp:1089
void setJSErrorsEnabled(bool enabled)
Definition: khtml_settings.cpp:1159
static void splitDomainAdvice(const QString &text, QString &domain, JavaScriptAdvice &javaAdvice, JavaScriptAdvice &javaScriptAdvice)
int daysTo(const QDateTime &other) const
static KPerDomainSettings & setup_per_domain_policy(KHTMLSettingsPrivate *const d, const QString &domain)
Returns a writeable per-domains settings instance for the given domain or a deep copy of the global s...
Definition: khtml_settings.cpp:203
QString adFilteredBy(const QString &url, bool *isWhiteListed=0) const
identify the filter which matches url.
Definition: khtml_settings.cpp:846
const_iterator constBegin() const
static const QString & availableFamilies()
Definition: khtml_settings.cpp:999
KJSWindowStatusPolicy windowStatusPolicy(const QString &hostname=QString()) const
Definition: khtml_settings.cpp:948
bool contains(const QString &str, Qt::CaseSensitivity cs) const
const char * name(StandardAction id)
void readDomainSettings(const KConfigGroup &config, bool reset, bool global, KPerDomainSettings &pd_settings)
reads from config's current group, forcing initialization if reset is true.
Definition: khtml_settings.cpp:240
bool isJavaEnabled(const QString &hostname=QString()) const
Definition: khtml_settings.cpp:906
KConfigGroup group(const QByteArray &group)
void writeEntry(const QString &key, const QVariant &value, WriteConfigFlags pFlags=Normal)
static const char * adviceToStr(KJavaScriptAdvice _advice)
Definition: khtml_settings.cpp:225
bool isJavaScriptEnabled(const QString &hostname=QString()) const
Definition: khtml_settings.cpp:911
QString join(const QString &separator) const
QString & remove(int position, int n)
KJSWindowMovePolicy
This enum specifies the policy for window.moveBy and .moveTo.
Definition: khtml_settings.h:93
static QDebug kDebug(bool cond, int area=KDE_DEFAULT_DEBUG_AREA)
KSmoothScrollingMode smoothScrolling() const
Definition: khtml_settings.cpp:1139
bool followSystemColors() const
Definition: khtml_settings.cpp:1099
void setStdFontName(const QString &n)
Definition: khtml_settings.cpp:1065
QByteArray data() const
KSharedConfigPtr config()
void setPattern(const QString &pattern)
static const KPerDomainSettings & lookup_hostname_policy(const KHTMLSettingsPrivate *const d, const QString &hostname)
Local helper for retrieving per-domain settings.
Definition: khtml_settings.cpp:754
bool isBackRightClickEnabled()
Definition: khtml_settings.cpp:813
QString number(int n, int base)
void append(const T &value)
QVariant property(const char *name) const
bool exists() const
JavaScriptAdvice
KJSWindowOpenPolicy windowOpenPolicy(const QString &hostname=QString()) const
Definition: khtml_settings.cpp:933
int toInt(bool *ok, int base) const
bool isAdFiltered(const QString &url) const
tests whether url is filtered.
Definition: khtml_settings.cpp:833
#define KDE_DEFAULT_CHANGECURSOR
bool isEmpty() const
const_iterator constEnd() const
bool isOpenMiddleClickEnabled()
Definition: khtml_settings.cpp:808
if(!yymsg) yymsg
bool startsWith(const QString &s, Qt::CaseSensitivity cs) const
KJSWindowMovePolicy windowMovePolicy(const QString &hostname=QString()) const
Definition: khtml_settings.cpp:938
typedef Iterator
iterator end()
QDateTime lastModified() const
bool jsPopupBlockerPassivePopup() const
Definition: khtml_settings.cpp:1192
KJSWindowStatusPolicy
This enum specifies the policy for window.status and .defaultStatus.
Definition: khtml_settings.h:85
StoredTransferJob * storedGet(const KUrl &url, LoadType reload=NoReload, JobFlags flags=DefaultFlags)
Definition: khtml_filter_p.h:59
bool isJavaScriptErrorReportingEnabled(const QString &hostname=QString()) const
Definition: khtml_settings.cpp:922
KAnimationAdvice showAnimations() const
Definition: khtml_settings.cpp:1134
iterator end()
QString toLower() const
QString family() const
bool exists() const
bool hasKey(const QString &key) const
static JavaScriptAdvice textToJavascriptAdvice(const QString &text)
const Key key(const T &value) const
QDateTime currentDateTime()
static QFont generalFont()
QString mid(int position, int n) const
void setJSPopupBlockerPassivePopup(bool enabled)
Definition: khtml_settings.cpp:1183
QStringList families(WritingSystem writingSystem) const
static QString locateLocal(const char *type, const QString &filename, const KComponentData &cData=KGlobal::mainComponent())
QString family() const
bool isValid() const
typedef ConstIterator
static KJavaScriptAdvice strToAdvice(const QString &_str)
Definition: khtml_settings.cpp:220
int length() const
QString errorString() const
static QDebug kWarning(bool cond, int area=KDE_DEFAULT_DEBUG_AREA)
QString fromLatin1(const char *str, int size)
void sort()
static const char * javascriptAdviceToText(JavaScriptAdvice advice)
bool isPluginsEnabled(const QString &hostname=QString()) const
Definition: khtml_settings.cpp:928
bool setProperty(const char *name, const QVariant &value)
iterator insert(const Key &key, const T &value)
KJSWindowResizePolicy windowResizePolicy(const QString &hostname=QString()) const
Definition: khtml_settings.cpp:943
typedef Iterator
#define HTML_DEFAULT_VIEW_SANSSERIF_FONT
Definition: khtmldefaults.h:30
void sync()
const_iterator constEnd() const
bool unfinishedImageFrame() const
Definition: khtml_settings.cpp:1129
const_iterator constBegin() const
KJavaScriptAdvice
This enum specifies whether Java/JavaScript execution is allowed.
Definition: khtml_settings.h:48
int size() const
bool connect(const QObject *sender, const char *signal, const QObject *receiver, const char *method, Qt::ConnectionType type)
static void splitDomainAdvice(const QString &configStr, QString &domain, KJavaScriptAdvice &javaAdvice, KJavaScriptAdvice &javaScriptAdvice)
Definition: khtml_settings.cpp:231
QString arg(qlonglong a, int fieldWidth, int base, const QChar &fillChar) const
QString toString() const
T readEntry(const QString &key, const T &aDefault) const
iterator find(const Key &key)
bool isAutoDelayedActionsEnabled() const
Definition: khtml_settings.cpp:1149
iterator begin()
KJSWindowResizePolicy
This enum specifies the policy for window.resizeBy and .resizeTo.
Definition: khtml_settings.h:101
static void error(QWidget *parent, const QString &text, const QString &caption=QString(), Options options=Notify)
QMap< QString, QString > entryMap() const
static QFont fixedFont()
QString errorText() const
int error() const
const T value(const Key &key) const
KJSWindowFocusPolicy
This enum specifies the policy for window.focus.
Definition: khtml_settings.h:109
KJSWindowFocusPolicy windowFocusPolicy(const QString &hostname=QString()) const
Definition: khtml_settings.cpp:953
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:26:19 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:26:19 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.