<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[244635] trunk</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/244635">244635</a></dd>
<dt>Author</dt> <dd>carlosgc@webkit.org</dd>
<dt>Date</dt> <dd>2019-04-24 22:51:01 -0700 (Wed, 24 Apr 2019)</dd>
</dl>

<h3>Log Message</h3>
<pre>[GTK] Hardcoded text color in input fields
https://bugs.webkit.org/show_bug.cgi?id=126907

Reviewed by Michael Catanzaro.

.:

Set and expose to build HAVE_OS_DARK_MODE_SUPPORT=1.

* Source/cmake/OptionsGTK.cmake:

Source/WebCore:

Enable HAVE_OS_DARK_MODE_SUPPORT for GTK port to ensure that dark mode is used when Page::useDarkAppearance()
returns true. This patch reverts <a href="http://trac.webkit.org/projects/webkit/changeset/232913">r232913</a>, I'll reopen the bug, I think we need to find a better solution for
that.

* CMakeLists.txt: Add HAVE_OS_DARK_MODE_SUPPORT to FEATURE_DEFINES_WITH_SPACE_SEPARATOR if enabled.
* css/CSSDefaultStyleSheets.cpp: Ensure html{color:text} is used in simple style sheet when
HAVE_OS_DARK_MODE_SUPPORT is enabled.
* page/FrameView.cpp:
(WebCore::FrameView::updateBackgroundRecursively): Use CSSValueWindowframe to get the frame view background
color when HAVE_OS_DARK_MODE_SUPPORT is enabled for non-mac ports.
* platform/gtk/RenderThemeWidget.cpp:
(WebCore::RenderThemeWidget::getOrCreate): Create window widget.
(WebCore::RenderThemeWindow::RenderThemeWindow): Add window widget.
* platform/gtk/RenderThemeWidget.h:
* rendering/RenderThemeGtk.cpp:
(WebCore::RenderThemeGtk::disabledTextColor const): Always use the color from the theme for consistency with
other form controls.
(WebCore::RenderThemeGtk::systemColor const): Get the color from the theme for CSSValueText, CSSValueGraytext
and CSSValueWindowframe.
* rendering/RenderThemeGtk.h:

Source/WebKit:

Implement PageClient::effectiveAppearanceIsDark() for GTK port.

* UIProcess/API/gtk/PageClientImpl.cpp:
(WebKit::PageClientImpl::effectiveAppearanceIsDark const): Check if gtk-application-prefer-dark-theme setting is
enabled, or the theme name contains the -dark suffix or the GTK_THEME environment variable contains the :dark suffix.
* UIProcess/API/gtk/PageClientImpl.h:
* UIProcess/API/gtk/WebKitWebViewBase.cpp:
(themeChanged): Notify the WebPageProxy that the theme has changed.
(webkitWebViewBaseSetToplevelOnScreenWindow): Connect to notify::gtk-application-prefer-dark-theme and notify::gtk-theme-name.
* WebProcess/WebPage/WebPage.cpp:
* WebProcess/WebPage/gtk/WebPageGtk.cpp:
(WebKit::WebPage::setUseDarkAppearance): Set gtk-application-prefer-dark-theme setting accordingly.

Source/WTF:

Define HAVE_OS_DARK_MODE_SUPPORT for GTK port.

* wtf/Platform.h:

Tools:

Add dark-mode command line option to MiniBrowser.

* MiniBrowser/gtk/main.c:
(main):

LayoutTests:

Remove expectations for tests that are passing again.

* platform/gtk/TestExpectations:</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkChangeLog">trunk/ChangeLog</a></li>
<li><a href="#trunkLayoutTestsChangeLog">trunk/LayoutTests/ChangeLog</a></li>
<li><a href="#trunkLayoutTestsplatformgtkTestExpectations">trunk/LayoutTests/platform/gtk/TestExpectations</a></li>
<li><a href="#trunkSourceWTFChangeLog">trunk/Source/WTF/ChangeLog</a></li>
<li><a href="#trunkSourceWTFwtfPlatformh">trunk/Source/WTF/wtf/Platform.h</a></li>
<li><a href="#trunkSourceWebCoreCMakeListstxt">trunk/Source/WebCore/CMakeLists.txt</a></li>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCorecssCSSDefaultStyleSheetscpp">trunk/Source/WebCore/css/CSSDefaultStyleSheets.cpp</a></li>
<li><a href="#trunkSourceWebCorepageFrameViewcpp">trunk/Source/WebCore/page/FrameView.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformgtkRenderThemeWidgetcpp">trunk/Source/WebCore/platform/gtk/RenderThemeWidget.cpp</a></li>
<li><a href="#trunkSourceWebCoreplatformgtkRenderThemeWidgeth">trunk/Source/WebCore/platform/gtk/RenderThemeWidget.h</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderThemeGtkcpp">trunk/Source/WebCore/rendering/RenderThemeGtk.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderThemeGtkh">trunk/Source/WebCore/rendering/RenderThemeGtk.h</a></li>
<li><a href="#trunkSourceWebKitChangeLog">trunk/Source/WebKit/ChangeLog</a></li>
<li><a href="#trunkSourceWebKitUIProcessAPIgtkPageClientImplcpp">trunk/Source/WebKit/UIProcess/API/gtk/PageClientImpl.cpp</a></li>
<li><a href="#trunkSourceWebKitUIProcessAPIgtkPageClientImplh">trunk/Source/WebKit/UIProcess/API/gtk/PageClientImpl.h</a></li>
<li><a href="#trunkSourceWebKitUIProcessAPIgtkWebKitWebViewBasecpp">trunk/Source/WebKit/UIProcess/API/gtk/WebKitWebViewBase.cpp</a></li>
<li><a href="#trunkSourceWebKitWebProcessWebPageWebPagecpp">trunk/Source/WebKit/WebProcess/WebPage/WebPage.cpp</a></li>
<li><a href="#trunkSourceWebKitWebProcessWebPagegtkWebPageGtkcpp">trunk/Source/WebKit/WebProcess/WebPage/gtk/WebPageGtk.cpp</a></li>
<li><a href="#trunkSourcecmakeOptionsGTKcmake">trunk/Source/cmake/OptionsGTK.cmake</a></li>
<li><a href="#trunkToolsChangeLog">trunk/Tools/ChangeLog</a></li>
<li><a href="#trunkToolsMiniBrowsergtkmainc">trunk/Tools/MiniBrowser/gtk/main.c</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/ChangeLog (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/ChangeLog  2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/ChangeLog     2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -1,3 +1,14 @@
</span><ins>+2019-04-24  Carlos Garcia Campos  <cgarcia@igalia.com>
+
+        [GTK] Hardcoded text color in input fields
+        https://bugs.webkit.org/show_bug.cgi?id=126907
+
+        Reviewed by Michael Catanzaro.
+
+        Set and expose to build HAVE_OS_DARK_MODE_SUPPORT=1.
+
+        * Source/cmake/OptionsGTK.cmake:
+
</ins><span class="cx"> 2019-04-23  Don Olmstead  <don.olmstead@sony.com>
</span><span class="cx"> 
</span><span class="cx">         [CMake][Win] Use target oriented design for WebKit
</span></span></pre></div>
<a id="trunkLayoutTestsChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/ChangeLog (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/ChangeLog      2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/LayoutTests/ChangeLog 2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -1,3 +1,14 @@
</span><ins>+2019-04-24  Carlos Garcia Campos  <cgarcia@igalia.com>
+
+        [GTK] Hardcoded text color in input fields
+        https://bugs.webkit.org/show_bug.cgi?id=126907
+
+        Reviewed by Michael Catanzaro.
+
+        Remove expectations for tests that are passing again.
+
+        * platform/gtk/TestExpectations:
+
</ins><span class="cx"> 2019-04-24  Simon Fraser  <simon.fraser@apple.com>
</span><span class="cx"> 
</span><span class="cx">         REGRESSION (r242132): Nested position:sticky elements move incorrectly
</span></span></pre></div>
<a id="trunkLayoutTestsplatformgtkTestExpectations"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/platform/gtk/TestExpectations (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/platform/gtk/TestExpectations  2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/LayoutTests/platform/gtk/TestExpectations     2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -1176,12 +1176,6 @@
</span><span class="cx"> # Test does not make sense for our platform
</span><span class="cx"> webkit.org/b/181659 fast/canvas/webgl/simulated-vertexAttrib0-invalid-indicies.html [ Skip ]
</span><span class="cx"> 
</span><del>-# When text input colors are set we do not style with GTK, so these reftests will fail
-webkit.org/b/186219 fast/forms/input-placeholder-text-indent.html [ ImageOnlyFailure ]
-webkit.org/b/186219 fast/forms/password-placeholder-text-security.html [ ImageOnlyFailure ]
-webkit.org/b/186219 fast/forms/placeholder-with-positioned-element.html [ ImageOnlyFailure ]
-webkit.org/b/186219 fast/forms/textarea-placeholder-wrapping.html [ ImageOnlyFailure ]
-
</del><span class="cx"> # This seems to be testing Apple-specific behavior?
</span><span class="cx"> css3/color-filters/color-filter-ignore-semantic.html [ ImageOnlyFailure ]
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWTFChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WTF/ChangeLog (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WTF/ChangeLog       2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/Source/WTF/ChangeLog  2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -1,3 +1,14 @@
</span><ins>+2019-04-24  Carlos Garcia Campos  <cgarcia@igalia.com>
+
+        [GTK] Hardcoded text color in input fields
+        https://bugs.webkit.org/show_bug.cgi?id=126907
+
+        Reviewed by Michael Catanzaro.
+
+        Define HAVE_OS_DARK_MODE_SUPPORT for GTK port.
+
+        * wtf/Platform.h:
+
</ins><span class="cx"> 2019-04-24  Tim Horton  <timothy_horton@apple.com>
</span><span class="cx"> 
</span><span class="cx">         Clean up WKActionSheetAssistant's use of LaunchServices
</span></span></pre></div>
<a id="trunkSourceWTFwtfPlatformh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WTF/wtf/Platform.h (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WTF/wtf/Platform.h  2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/Source/WTF/wtf/Platform.h     2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -1416,7 +1416,7 @@
</span><span class="cx"> #endif
</span><span class="cx"> #endif
</span><span class="cx"> 
</span><del>-#if PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101400
</del><ins>+#if (PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101400) || PLATFORM(GTK)
</ins><span class="cx"> #define HAVE_OS_DARK_MODE_SUPPORT 1
</span><span class="cx"> #endif
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCoreCMakeListstxt"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/CMakeLists.txt (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/CMakeLists.txt      2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/Source/WebCore/CMakeLists.txt 2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -1682,6 +1682,10 @@
</span><span class="cx">     )
</span><span class="cx"> endif ()
</span><span class="cx"> 
</span><ins>+if (HAVE_OS_DARK_MODE_SUPPORT)
+    set(FEATURE_DEFINES_WITH_SPACE_SEPARATOR "${FEATURE_DEFINES_WITH_SPACE_SEPARATOR} HAVE_OS_DARK_MODE_SUPPORT")
+endif ()
+
</ins><span class="cx"> set(WebCoreTestSupport_PRIVATE_INCLUDE_DIRECTORIES
</span><span class="cx">     "${WEBCORE_DIR}/platform/mock"
</span><span class="cx">     "${WEBCORE_DIR}/testing"
</span></span></pre></div>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog   2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/Source/WebCore/ChangeLog      2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -1,3 +1,31 @@
</span><ins>+2019-04-24  Carlos Garcia Campos  <cgarcia@igalia.com>
+
+        [GTK] Hardcoded text color in input fields
+        https://bugs.webkit.org/show_bug.cgi?id=126907
+
+        Reviewed by Michael Catanzaro.
+
+        Enable HAVE_OS_DARK_MODE_SUPPORT for GTK port to ensure that dark mode is used when Page::useDarkAppearance()
+        returns true. This patch reverts r232913, I'll reopen the bug, I think we need to find a better solution for
+        that.
+
+        * CMakeLists.txt: Add HAVE_OS_DARK_MODE_SUPPORT to FEATURE_DEFINES_WITH_SPACE_SEPARATOR if enabled.
+        * css/CSSDefaultStyleSheets.cpp: Ensure html{color:text} is used in simple style sheet when
+        HAVE_OS_DARK_MODE_SUPPORT is enabled.
+        * page/FrameView.cpp:
+        (WebCore::FrameView::updateBackgroundRecursively): Use CSSValueWindowframe to get the frame view background
+        color when HAVE_OS_DARK_MODE_SUPPORT is enabled for non-mac ports.
+        * platform/gtk/RenderThemeWidget.cpp:
+        (WebCore::RenderThemeWidget::getOrCreate): Create window widget.
+        (WebCore::RenderThemeWindow::RenderThemeWindow): Add window widget.
+        * platform/gtk/RenderThemeWidget.h:
+        * rendering/RenderThemeGtk.cpp:
+        (WebCore::RenderThemeGtk::disabledTextColor const): Always use the color from the theme for consistency with
+        other form controls.
+        (WebCore::RenderThemeGtk::systemColor const): Get the color from the theme for CSSValueText, CSSValueGraytext
+        and CSSValueWindowframe.
+        * rendering/RenderThemeGtk.h:
+
</ins><span class="cx"> 2019-04-24  Zalan Bujtas  <zalan@apple.com>
</span><span class="cx"> 
</span><span class="cx">         Regression (r244291): Broken API Test AutoLayoutRenderingProgressRelativeOrdering
</span></span></pre></div>
<a id="trunkSourceWebCorecssCSSDefaultStyleSheetscpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/css/CSSDefaultStyleSheets.cpp (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/css/CSSDefaultStyleSheets.cpp       2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/Source/WebCore/css/CSSDefaultStyleSheets.cpp  2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -81,8 +81,8 @@
</span><span class="cx"> #endif
</span><span class="cx"> 
</span><span class="cx"> // FIXME: It would be nice to use some mechanism that guarantees this is in sync with the real UA stylesheet.
</span><del>-#if PLATFORM(MAC)
-// The only difference in the simple style sheet for macOS is the addition of html{color:text}.
</del><ins>+#if HAVE(OS_DARK_MODE_SUPPORT)
+// The only difference in the simple style sheet for dark mode is the addition of html{color:text}.
</ins><span class="cx"> static const char* simpleUserAgentStyleSheet = "html,body,div{display:block}html{color:text}head{display:none}body{margin:8px}div:focus,span:focus,a:focus{outline:auto 5px -webkit-focus-ring-color}a:any-link{color:-webkit-link;text-decoration:underline}a:any-link:active{color:-webkit-activelink}";
</span><span class="cx"> #else
</span><span class="cx"> static const char* simpleUserAgentStyleSheet = "html,body,div{display:block}head{display:none}body{margin:8px}div:focus,span:focus,a:focus{outline:auto 5px -webkit-focus-ring-color}a:any-link{color:-webkit-link;text-decoration:underline}a:any-link:active{color:-webkit-activelink}";
</span></span></pre></div>
<a id="trunkSourceWebCorepageFrameViewcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/page/FrameView.cpp (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/page/FrameView.cpp  2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/Source/WebCore/page/FrameView.cpp     2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -3000,9 +3000,14 @@
</span><span class="cx"> 
</span><span class="cx"> void FrameView::updateBackgroundRecursively(const Optional<Color>& backgroundColor)
</span><span class="cx"> {
</span><del>-#if HAVE(OS_DARK_MODE_SUPPORT) && ENABLE(DARK_MODE_CSS)
-    Color baseBackgroundColor = backgroundColor.valueOr(RenderTheme::singleton().systemColor(CSSValueAppleSystemControlBackground, styleColorOptions()));
</del><ins>+#if HAVE(OS_DARK_MODE_SUPPORT)
+#if PLATFORM(MAC) || PLATFORM(IOS_FAMILY)
+    static const auto cssValueControlBackground = CSSValueAppleSystemControlBackground;
</ins><span class="cx"> #else
</span><ins>+    static const auto cssValueControlBackground = CSSValueWindowframe;
+#endif
+    Color baseBackgroundColor = backgroundColor.valueOr(RenderTheme::singleton().systemColor(cssValueControlBackground, styleColorOptions()));
+#else
</ins><span class="cx">     Color baseBackgroundColor = backgroundColor.valueOr(Color::white);
</span><span class="cx"> #endif
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformgtkRenderThemeWidgetcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/gtk/RenderThemeWidget.cpp (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/gtk/RenderThemeWidget.cpp  2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/Source/WebCore/platform/gtk/RenderThemeWidget.cpp     2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -85,6 +85,8 @@
</span><span class="cx">             return std::make_unique<RenderThemeListView>();
</span><span class="cx">         case RenderThemeWidget::Type::Icon:
</span><span class="cx">             return std::make_unique<RenderThemeIcon>();
</span><ins>+        case RenderThemeWidget::Type::Window:
+            return std::make_unique<RenderThemeWindow>();
</ins><span class="cx">         }
</span><span class="cx">         ASSERT_NOT_REACHED();
</span><span class="cx">         return nullptr;
</span><span class="lines">@@ -293,6 +295,11 @@
</span><span class="cx"> {
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+RenderThemeWindow::RenderThemeWindow()
+    : m_window(RenderThemeGadget::create({ RenderThemeGadget::Type::Generic, "window", { "background" } }))
+{
+}
+
</ins><span class="cx"> } // namepsace WebCore
</span><span class="cx"> 
</span><span class="cx"> #endif // GTK_CHECK_VERSION(3, 20, 0)
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformgtkRenderThemeWidgeth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/gtk/RenderThemeWidget.h (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/gtk/RenderThemeWidget.h    2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/Source/WebCore/platform/gtk/RenderThemeWidget.h       2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -59,6 +59,7 @@
</span><span class="cx">         IndeterminateProgressBar,
</span><span class="cx">         ListView,
</span><span class="cx">         Icon,
</span><ins>+        Window,
</ins><span class="cx">     };
</span><span class="cx">     static RenderThemeWidget& getOrCreate(Type);
</span><span class="cx">     static void clearCache();
</span><span class="lines">@@ -233,6 +234,18 @@
</span><span class="cx">     std::unique_ptr<RenderThemeGadget> m_icon;
</span><span class="cx"> };
</span><span class="cx"> 
</span><ins>+class RenderThemeWindow final : public RenderThemeWidget {
+public:
+    RenderThemeWindow();
+    ~RenderThemeWindow() = default;
+
+    RenderThemeGadget& window() const { return *m_window; }
+
+private:
+    std::unique_ptr<RenderThemeGadget> m_window;
+
+};
+
</ins><span class="cx"> } // namespace WebCore
</span><span class="cx"> 
</span><span class="cx"> #endif // GTK_CHECK_VERSION(3, 20, 0)
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderThemeGtkcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderThemeGtk.cpp (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderThemeGtk.cpp        2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/Source/WebCore/rendering/RenderThemeGtk.cpp   2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -167,6 +167,9 @@
</span><span class="cx"> #if ENABLE(VIDEO)
</span><span class="cx">     MediaButton,
</span><span class="cx"> #endif
</span><ins>+#if GTK_CHECK_VERSION(3, 20, 0)
+    Window,
+#endif
</ins><span class="cx"> };
</span><span class="cx"> 
</span><span class="cx"> #if !GTK_CHECK_VERSION(3, 20, 0)
</span><span class="lines">@@ -926,15 +929,6 @@
</span><span class="cx">     return paintMenuList(object, info, rect);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-bool RenderThemeGtk::isControlStyled(const RenderStyle& style, const BorderData& border, const FillLayer& background, const Color& backgroundColor) const
-{
-    // To avoid rendering issues with dark themes, if text input elements have color styling, we don't style them with GTK.
-    if ((style.appearance() == TextFieldPart || style.appearance() == TextAreaPart || style.appearance() == SearchFieldPart) && style.color() != RenderStyle::initialColor())
-        return true;
-
-    return RenderTheme::isControlStyled(style, border, background, backgroundColor);
-}
-
</del><span class="cx"> #if GTK_CHECK_VERSION(3, 20, 0)
</span><span class="cx"> 
</span><span class="cx"> static IntSize spinButtonSize()
</span><span class="lines">@@ -1706,6 +1700,9 @@
</span><span class="cx">     case Button:
</span><span class="cx">         gadget = &static_cast<RenderThemeButton&>(RenderThemeWidget::getOrCreate(RenderThemeWidget::Type::Button)).button();
</span><span class="cx">         break;
</span><ins>+    case Window:
+        gadget = &static_cast<RenderThemeWindow&>(RenderThemeWidget::getOrCreate(RenderThemeWidget::Type::Window)).window();
+        break;
</ins><span class="cx">     }
</span><span class="cx"> 
</span><span class="cx">     ASSERT(gadget);
</span><span class="lines">@@ -1767,6 +1764,11 @@
</span><span class="cx">     return styleColor(ListBox, GTK_STATE_FLAG_SELECTED, StyleColorForeground);
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+Color RenderThemeGtk::disabledTextColor(const Color&, const Color&) const
+{
+    return styleColor(Entry, GTK_STATE_FLAG_INSENSITIVE, StyleColorForeground);
+}
+
</ins><span class="cx"> Color RenderThemeGtk::systemColor(CSSValueID cssValueId, OptionSet<StyleColor::Options> options) const
</span><span class="cx"> {
</span><span class="cx">     switch (cssValueId) {
</span><span class="lines">@@ -1774,6 +1776,14 @@
</span><span class="cx">         return styleColor(Button, GTK_STATE_FLAG_ACTIVE, StyleColorForeground);
</span><span class="cx">     case CSSValueCaptiontext:
</span><span class="cx">         return styleColor(Entry, GTK_STATE_FLAG_ACTIVE, StyleColorForeground);
</span><ins>+    case CSSValueText:
+        return styleColor(Entry, GTK_STATE_FLAG_ACTIVE, StyleColorForeground);
+    case CSSValueGraytext:
+        return styleColor(Entry, GTK_STATE_FLAG_INSENSITIVE, StyleColorForeground);
+#if GTK_CHECK_VERSION(3, 20, 0)
+    case CSSValueWindowframe:
+        return styleColor(Window, GTK_STATE_FLAG_ACTIVE, StyleColorBackground);
+#endif
</ins><span class="cx">     default:
</span><span class="cx">         return RenderTheme::systemColor(cssValueId, options);
</span><span class="cx">     }
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderThemeGtkh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderThemeGtk.h (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderThemeGtk.h  2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/Source/WebCore/rendering/RenderThemeGtk.h     2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -81,6 +81,8 @@
</span><span class="cx">     Color platformInactiveListBoxSelectionBackgroundColor(OptionSet<StyleColor::Options>) const override;
</span><span class="cx">     Color platformInactiveListBoxSelectionForegroundColor(OptionSet<StyleColor::Options>) const override;
</span><span class="cx"> 
</span><ins>+    Color disabledTextColor(const Color&, const Color&) const override;
+
</ins><span class="cx">     Seconds caretBlinkInterval() const override;
</span><span class="cx"> 
</span><span class="cx">     void platformColorsDidChange() override;
</span><span class="lines">@@ -168,8 +170,6 @@
</span><span class="cx"> #endif
</span><span class="cx"> #endif
</span><span class="cx"> 
</span><del>-    bool isControlStyled(const RenderStyle&, const BorderData&, const FillLayer&, const Color&) const override;
-
</del><span class="cx">     Seconds animationRepeatIntervalForProgressBar(RenderProgress&) const override;
</span><span class="cx">     Seconds animationDurationForProgressBar(RenderProgress&) const override;
</span><span class="cx">     void adjustProgressBarStyle(StyleResolver&, RenderStyle&, const Element*) const override;
</span></span></pre></div>
<a id="trunkSourceWebKitChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/ChangeLog (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/ChangeLog    2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/Source/WebKit/ChangeLog       2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -1,3 +1,23 @@
</span><ins>+2019-04-24  Carlos Garcia Campos  <cgarcia@igalia.com>
+
+        [GTK] Hardcoded text color in input fields
+        https://bugs.webkit.org/show_bug.cgi?id=126907
+
+        Reviewed by Michael Catanzaro.
+
+        Implement PageClient::effectiveAppearanceIsDark() for GTK port.
+
+        * UIProcess/API/gtk/PageClientImpl.cpp:
+        (WebKit::PageClientImpl::effectiveAppearanceIsDark const): Check if gtk-application-prefer-dark-theme setting is
+        enabled, or the theme name contains the -dark suffix or the GTK_THEME environment variable contains the :dark suffix.
+        * UIProcess/API/gtk/PageClientImpl.h:
+        * UIProcess/API/gtk/WebKitWebViewBase.cpp:
+        (themeChanged): Notify the WebPageProxy that the theme has changed.
+        (webkitWebViewBaseSetToplevelOnScreenWindow): Connect to notify::gtk-application-prefer-dark-theme and notify::gtk-theme-name.
+        * WebProcess/WebPage/WebPage.cpp:
+        * WebProcess/WebPage/gtk/WebPageGtk.cpp:
+        (WebKit::WebPage::setUseDarkAppearance): Set gtk-application-prefer-dark-theme setting accordingly.
+
</ins><span class="cx"> 2019-04-24  Zalan Bujtas  <zalan@apple.com>
</span><span class="cx"> 
</span><span class="cx">         Regression (r244291): Broken API Test AutoLayoutRenderingProgressRelativeOrdering
</span></span></pre></div>
<a id="trunkSourceWebKitUIProcessAPIgtkPageClientImplcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/UIProcess/API/gtk/PageClientImpl.cpp (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/UIProcess/API/gtk/PageClientImpl.cpp 2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/Source/WebKit/UIProcess/API/gtk/PageClientImpl.cpp    2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -533,4 +533,23 @@
</span><span class="cx">     completionHandler(WebCore::DOMPasteAccessResponse::DeniedForGesture);
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+bool PageClientImpl::effectiveAppearanceIsDark() const
+{
+    auto* settings = gtk_widget_get_settings(m_viewWidget);
+    gboolean preferDarkTheme;
+    g_object_get(settings, "gtk-application-prefer-dark-theme", &preferDarkTheme, nullptr);
+    if (preferDarkTheme)
+        return true;
+
+    GUniqueOutPtr<char> themeName;
+    g_object_get(settings, "gtk-theme-name", &themeName.outPtr(), nullptr);
+    if (g_str_has_suffix(themeName.get(), "-dark"))
+        return true;
+
+    if (auto* themeNameEnv = g_getenv("GTK_THEME"))
+        return g_str_has_suffix(themeNameEnv, ":dark");
+
+    return false;
+}
+
</ins><span class="cx"> } // namespace WebKit
</span></span></pre></div>
<a id="trunkSourceWebKitUIProcessAPIgtkPageClientImplh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/UIProcess/API/gtk/PageClientImpl.h (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/UIProcess/API/gtk/PageClientImpl.h   2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/Source/WebKit/UIProcess/API/gtk/PageClientImpl.h      2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -162,6 +162,8 @@
</span><span class="cx"> 
</span><span class="cx">     WebCore::UserInterfaceLayoutDirection userInterfaceLayoutDirection() override { return WebCore::UserInterfaceLayoutDirection::LTR; }
</span><span class="cx"> 
</span><ins>+    bool effectiveAppearanceIsDark() const override;
+
</ins><span class="cx">     // Members of PageClientImpl class
</span><span class="cx">     GtkWidget* m_viewWidget;
</span><span class="cx">     DefaultUndoController m_undoController;
</span></span></pre></div>
<a id="trunkSourceWebKitUIProcessAPIgtkWebKitWebViewBasecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/UIProcess/API/gtk/WebKitWebViewBase.cpp (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/UIProcess/API/gtk/WebKitWebViewBase.cpp      2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/Source/WebKit/UIProcess/API/gtk/WebKitWebViewBase.cpp 2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -183,6 +183,8 @@
</span><span class="cx">     unsigned long toplevelFocusOutEventID { 0 };
</span><span class="cx">     unsigned long toplevelWindowStateEventID { 0 };
</span><span class="cx">     unsigned long toplevelWindowRealizedID { 0 };
</span><ins>+    unsigned long themeChangedID { 0 };
+    unsigned long applicationPreferDarkThemeID { 0 };
</ins><span class="cx"> 
</span><span class="cx">     // View State.
</span><span class="cx">     OptionSet<ActivityState::Flag> activityState;
</span><span class="lines">@@ -265,6 +267,11 @@
</span><span class="cx">     return FALSE;
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+static void themeChanged(WebKitWebViewBase* webViewBase)
+{
+    webViewBase->priv->pageProxy->effectiveAppearanceDidChange();
+}
+
</ins><span class="cx"> static void toplevelWindowRealized(WebKitWebViewBase* webViewBase)
</span><span class="cx"> {
</span><span class="cx">     gtk_widget_realize(GTK_WIDGET(webViewBase));
</span><span class="lines">@@ -298,6 +305,17 @@
</span><span class="cx">         g_signal_handler_disconnect(priv->toplevelOnScreenWindow, priv->toplevelWindowRealizedID);
</span><span class="cx">         priv->toplevelWindowRealizedID = 0;
</span><span class="cx">     }
</span><ins>+    if (priv->themeChangedID || priv->applicationPreferDarkThemeID) {
+        auto* settings = gtk_widget_get_settings(GTK_WIDGET(priv->toplevelOnScreenWindow));
+        if (priv->themeChangedID) {
+            g_signal_handler_disconnect(settings, priv->themeChangedID);
+            priv->themeChangedID = 0;
+        }
+        if (priv->applicationPreferDarkThemeID) {
+            g_signal_handler_disconnect(settings, priv->applicationPreferDarkThemeID);
+            priv->applicationPreferDarkThemeID = 0;
+        }
+    }
</ins><span class="cx"> 
</span><span class="cx">     priv->toplevelOnScreenWindow = window;
</span><span class="cx"> 
</span><span class="lines">@@ -326,6 +344,12 @@
</span><span class="cx">     priv->toplevelWindowStateEventID =
</span><span class="cx">         g_signal_connect(priv->toplevelOnScreenWindow, "window-state-event", G_CALLBACK(toplevelWindowStateEvent), webViewBase);
</span><span class="cx"> 
</span><ins>+    auto* settings = gtk_widget_get_settings(GTK_WIDGET(priv->toplevelOnScreenWindow));
+    priv->themeChangedID =
+        g_signal_connect_swapped(settings, "notify::gtk-theme-name", G_CALLBACK(themeChanged), webViewBase);
+    priv->applicationPreferDarkThemeID =
+        g_signal_connect_swapped(settings, "notify::gtk-application-prefer-dark-theme", G_CALLBACK(themeChanged), webViewBase);
+
</ins><span class="cx">     if (gtk_widget_get_realized(GTK_WIDGET(window)))
</span><span class="cx">         gtk_widget_realize(GTK_WIDGET(webViewBase));
</span><span class="cx">     else
</span></span></pre></div>
<a id="trunkSourceWebKitWebProcessWebPageWebPagecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/WebProcess/WebPage/WebPage.cpp (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/WebProcess/WebPage/WebPage.cpp       2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/Source/WebKit/WebProcess/WebPage/WebPage.cpp  2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -4610,10 +4610,12 @@
</span><span class="cx"> 
</span><span class="cx"> #endif
</span><span class="cx"> 
</span><ins>+#if !PLATFORM(GTK)
</ins><span class="cx"> void WebPage::setUseDarkAppearance(bool useDarkAppearance)
</span><span class="cx"> {
</span><span class="cx">     corePage()->setUseDarkAppearance(useDarkAppearance);
</span><span class="cx"> }
</span><ins>+#endif
</ins><span class="cx"> 
</span><span class="cx"> void WebPage::beginPrinting(uint64_t frameID, const PrintInfo& printInfo)
</span><span class="cx"> {
</span></span></pre></div>
<a id="trunkSourceWebKitWebProcessWebPagegtkWebPageGtkcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/WebProcess/WebPage/gtk/WebPageGtk.cpp (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/WebProcess/WebPage/gtk/WebPageGtk.cpp        2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/Source/WebKit/WebProcess/WebPage/gtk/WebPageGtk.cpp   2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -195,4 +195,11 @@
</span><span class="cx">     frame->coreFrame()->selection().setBase(selection.extent(), selection.affinity());
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+void WebPage::setUseDarkAppearance(bool useDarkAppearance)
+{
+    if (auto* settings = gtk_settings_get_default())
+        g_object_set(settings, "gtk-application-prefer-dark-theme", useDarkAppearance, nullptr);
+    corePage()->setUseDarkAppearance(useDarkAppearance);
+}
+
</ins><span class="cx"> } // namespace WebKit
</span></span></pre></div>
<a id="trunkSourcecmakeOptionsGTKcmake"></a>
<div class="modfile"><h4>Modified: trunk/Source/cmake/OptionsGTK.cmake (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/cmake/OptionsGTK.cmake      2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/Source/cmake/OptionsGTK.cmake 2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -192,6 +192,7 @@
</span><span class="cx"> 
</span><span class="cx"> SET_AND_EXPOSE_TO_BUILD(HAVE_GTK_GESTURES ${GTK3_SUPPORTS_GESTURES})
</span><span class="cx"> SET_AND_EXPOSE_TO_BUILD(HAVE_GTK_UNIX_PRINTING ${GTKUnixPrint_FOUND})
</span><ins>+SET_AND_EXPOSE_TO_BUILD(HAVE_OS_DARK_MODE_SUPPORT 1)
</ins><span class="cx"> 
</span><span class="cx"> set(glib_components gio gio-unix gobject gthread gmodule)
</span><span class="cx"> find_package(GLIB 2.36 REQUIRED COMPONENTS ${glib_components})
</span></span></pre></div>
<a id="trunkToolsChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Tools/ChangeLog (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/ChangeLog    2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/Tools/ChangeLog       2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -1,3 +1,15 @@
</span><ins>+2019-04-24  Carlos Garcia Campos  <cgarcia@igalia.com>
+
+        [GTK] Hardcoded text color in input fields
+        https://bugs.webkit.org/show_bug.cgi?id=126907
+
+        Reviewed by Michael Catanzaro.
+
+        Add dark-mode command line option to MiniBrowser.
+
+        * MiniBrowser/gtk/main.c:
+        (main):
+
</ins><span class="cx"> 2019-04-24  Zalan Bujtas  <zalan@apple.com>
</span><span class="cx"> 
</span><span class="cx">         Regression (r244291): Broken API Test AutoLayoutRenderingProgressRelativeOrdering
</span></span></pre></div>
<a id="trunkToolsMiniBrowsergtkmainc"></a>
<div class="modfile"><h4>Modified: trunk/Tools/MiniBrowser/gtk/main.c (244634 => 244635)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/MiniBrowser/gtk/main.c       2019-04-25 05:09:59 UTC (rev 244634)
+++ trunk/Tools/MiniBrowser/gtk/main.c  2019-04-25 05:51:01 UTC (rev 244635)
</span><span class="lines">@@ -52,6 +52,7 @@
</span><span class="cx"> static const char *cookiesFile;
</span><span class="cx"> static const char *cookiesPolicy;
</span><span class="cx"> static const char *proxy;
</span><ins>+static gboolean darkMode;
</ins><span class="cx"> 
</span><span class="cx"> typedef enum {
</span><span class="cx">     MINI_BROWSER_ERROR_INVALID_ABOUT_PATH
</span><span class="lines">@@ -103,6 +104,7 @@
</span><span class="cx"> {
</span><span class="cx">     { "bg-color", 0, 0, G_OPTION_ARG_CALLBACK, parseBackgroundColor, "Background color", NULL },
</span><span class="cx">     { "editor-mode", 'e', 0, G_OPTION_ARG_NONE, &editorMode, "Run in editor mode", NULL },
</span><ins>+    { "dark-mode", 'd', 0, G_OPTION_ARG_NONE, &darkMode, "Run in dark mode", NULL },
</ins><span class="cx">     { "session-file", 's', 0, G_OPTION_ARG_FILENAME, &sessionFile, "Session file", "FILE" },
</span><span class="cx">     { "geometry", 'g', 0, G_OPTION_ARG_STRING, &geometry, "Set the size and position of the window (WIDTHxHEIGHT+X+Y)", "GEOMETRY" },
</span><span class="cx">     { "full-screen", 'f', 0, G_OPTION_ARG_NONE, &fullScreen, "Set the window to full-screen mode", NULL },
</span><span class="lines">@@ -584,6 +586,8 @@
</span><span class="cx">         webkit_web_context_set_tls_errors_policy(webContext, WEBKIT_TLS_ERRORS_POLICY_IGNORE);
</span><span class="cx"> 
</span><span class="cx">     BrowserWindow *mainWindow = BROWSER_WINDOW(browser_window_new(NULL, webContext));
</span><ins>+    if (darkMode)
+        g_object_set(gtk_widget_get_settings(GTK_WIDGET(mainWindow)), "gtk-application-prefer-dark-theme", TRUE, NULL);
</ins><span class="cx">     if (fullScreen)
</span><span class="cx">         gtk_window_fullscreen(GTK_WINDOW(mainWindow));
</span><span class="cx">     else if (geometry)
</span></span></pre>
</div>
</div>

</body>
</html>