From f37aadbb2de64d9a8f302cf89c004eccb9834e93 Mon Sep 17 00:00:00 2001 From: "Jonas M. Gastal" Date: Wed, 19 Aug 2009 22:03:56 -0300 Subject: Implements the ability of the user to apply a user defined CSS to all web pages. --- src/mainwindow.cpp | 5 +++++ src/rekonq.kcfg | 3 +++ src/settings_webkit.ui | 47 ++++++++++++++++++++++++++++++++++------------- 3 files changed, 42 insertions(+), 13 deletions(-) (limited to 'src') diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 4ed885bc..29044745 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -447,6 +447,11 @@ void MainWindow::slotUpdateConfiguration() defaultSettings->setAttribute(QWebSettings::OfflineStorageDatabaseEnabled, ReKonfig::offlineStorageDatabaseEnabled()); defaultSettings->setAttribute(QWebSettings::OfflineWebApplicationCacheEnabled, ReKonfig::offlineWebApplicationCacheEnabled()); defaultSettings->setAttribute(QWebSettings::LocalStorageDatabaseEnabled, ReKonfig::localStorageDatabaseEnabled()); + /** + * Applies user defined CSS to all open webpages. If there no longer is a + * user defined CSS removes it from all open webpages. + */ + defaultSettings->setUserStyleSheetUrl(ReKonfig::userCSS()); // ====== load Settings on main classes Application::networkAccessManager()->loadSettings(); diff --git a/src/rekonq.kcfg b/src/rekonq.kcfg index ec2b9a3b..443c9f8d 100644 --- a/src/rekonq.kcfg +++ b/src/rekonq.kcfg @@ -111,6 +111,9 @@ true + + + diff --git a/src/settings_webkit.ui b/src/settings_webkit.ui index a28ce915..dbdd7a34 100644 --- a/src/settings_webkit.ui +++ b/src/settings_webkit.ui @@ -6,7 +6,7 @@ 0 0 - 564 + 622 360 @@ -17,49 +17,49 @@ WebKit Settings - + Autoload images - + Qt::Vertical - + Links included in focus chain - + JavaScript support - + Zoom text only - + Java support - + Print element backgrounds @@ -73,41 +73,55 @@ - + Offline storage database - + JavaScript can open windows - + Offline web application cache - + JavaScript can access clipboard - + Local storage database + + + + User CSS: + + + + + + + *.css + + + @@ -126,6 +140,13 @@ + + + KUrlRequester + QFrame +
kurlrequester.h
+
+
-- cgit v1.2.1 From 46fd1107559386a6e4c161408a7eefeea4dab14a Mon Sep 17 00:00:00 2001 From: Andrea Diamantini Date: Mon, 24 Aug 2009 10:24:06 +0200 Subject: Fixed a bit setting_webkit.ui --- src/settings_webkit.ui | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/settings_webkit.ui b/src/settings_webkit.ui index dbdd7a34..129bcf03 100644 --- a/src/settings_webkit.ui +++ b/src/settings_webkit.ui @@ -108,14 +108,23 @@ - + + + + + + + User Style Sheet + + + - User CSS: + User CSS path: - + *.css @@ -133,7 +142,7 @@ 20 - 146 + 40 -- cgit v1.2.1