[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-core-devel
Subject:    Re: Review Request 120363: proposal to use the NOGUI switch in CMake files to set the default value 
From:       Thomas_Lübking <thomas.luebking () gmail ! com>
Date:       2014-09-25 22:10:42
Message-ID: 20140925221042.6970.22766 () probe ! kde ! org
[Download RAW message or body]

--===============8258688310228018905==
MIME-Version: 1.0
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: 8bit



> On Sept. 25, 2014, 6:07 nachm., Thomas Lübking wrote:
> > Aside Thiagos concern, what actually causes the menubar/docker item stuff?
> > 
> > Quoting QApplication (4.8):
> > > On X11, the window system is initialized if GUIenabled is true. If GUIenabled \
> > > is false, the application does not connect to the X server. On Windows and Mac \
> > > OS, currently the window system is always initialized, regardless of the value \
> > > of GUIenabled. This may change in future versions of Qt.
> > 
> > So it's perhaps rather a statement in KApplicationPrivate::init() which causes \
> > this? There aren't too many depending on GUIEnabled ... ;-)
> 
> René J.V. Bertin wrote:
> Thiagos?
> 
> The menubar/Dock "item stuff" is the result of `qt_mac_loadMenuNib` in \
> `qapplication_mac.mm`, which is called when \
> `!QApplication::testAttribute(Qt::AA_MacPluginApplication)`. Setting \
> `GUIenabled=false` has that effect, ultimately.

> Thiagos?

By mail:
http://lists.kde.org/?l=kde-core-devel&m=141166670217317&w=2

> result of qt_mac_loadMenuNib in qapplication_mac.mm

Ok, so the API doc lied to me ;-)
Since the attributes are static, you could simply set it before creating the \
application in the relevant main funcs, could you? (Though i actually don't see it \
set anywhere - but it's late and i'm tired...)


- Thomas


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/120363/#review67442
-----------------------------------------------------------


On Sept. 25, 2014, 1:32 nachm., René J.V. Bertin wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/120363/
> -----------------------------------------------------------
> 
> (Updated Sept. 25, 2014, 1:32 nachm.)
> 
> 
> Review request for KDE Software on Mac OS X and kdelibs.
> 
> 
> Repository: kdelibs
> 
> 
> Description
> -------
> 
> Applications can be defined in their CMake file as being `NOGUI`, but until now \
> this has had very limited effect. Especially on OS X, those applications can still \
> construct a minimal GUI and thus have "visual presence" in the Dock and application \
> switcher (and have a menubar as well). 
> This patch proposes to define a preprocessor token, `KDE_WITHOUT_GUI`, for those \
> targets, and uses that token to set the default value for the `GUIenabled` option \
> of the `KApplication` and `KUniqueApplication` classes. 
> This could potentially be combined on OS X with the CoreFoundation call that turns \
> a running application into an "agent" (see \
> https://git.reviewboard.kde.org/r/120354). 
> 
> Diffs
> -----
> 
> cmake/modules/KDE4Macros.cmake 073d726 
> kdeui/kernel/kapplication.h fa2ab26 
> kdeui/kernel/kapplication.cpp b093034 
> kdeui/kernel/kuniqueapplication.h e05dcd7 
> 
> Diff: https://git.reviewboard.kde.org/r/120363/diff/
> 
> 
> Testing
> -------
> 
> On OS X 10.6.8 with kdelibs 4.14.1 (git/kde4.14), rebuilt kdelibs, kde-workspace, \
> kde-runtime, kde-baseapps, kdepim-runtime and nepomuk-core. If the documentation I \
> read is correct, the `GUIenabled` switch has no effect on Linux, so this patch \
> shouldn't have any either on that OS. 
> 
> Thanks,
> 
> René J.V. Bertin
> 
> 


--===============8258688310228018905==
MIME-Version: 1.0
Content-Type: text/html; charset="utf-8"
Content-Transfer-Encoding: 8bit




<html>
 <body>
  <div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
   <table bgcolor="#f9f3c9" width="100%" cellpadding="12" style="border: 1px #c9c399 \
solid; border-radius: 6px; -moz-border-radius: 6px; -webkit-border-radius: 6px;">  \
<tr>  <td>
      This is an automatically generated e-mail. To reply, visit:
      <a href="https://git.reviewboard.kde.org/r/120363/">https://git.reviewboard.kde.org/r/120363/</a>
  </td>
    </tr>
   </table>
   <br />





<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <p style="margin-top: 0;">On September 25th, 2014, 6:07 nachm. UTC, \
<b>Thomas Lübking</b> wrote:</p>  <blockquote style="margin-left: 1em; border-left: \
2px solid #d0d0d0; padding-left: 10px;">  <pre style="white-space: pre-wrap; \
white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; \
word-wrap: break-word;"><p style="padding: 0;text-rendering: inherit;margin: \
0;line-height: inherit;white-space: inherit;">Aside Thiagos concern, what actually \
causes the menubar/docker item stuff?</p> <p style="padding: 0;text-rendering: \
inherit;margin: 0;line-height: inherit;white-space: inherit;">Quoting QApplication \
(4.8):</p> <blockquote style="text-rendering: inherit;padding: 0 0 0 1em;border-left: \
1px solid #bbb;white-space: normal;margin: 0 0 0 0.5em;line-height: inherit;"> <p \
style="padding: 0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: \
inherit;">On X11, the window system is initialized if GUIenabled is true. If \
GUIenabled is false, the application does not connect to the X server. On Windows and \
Mac OS, currently the window system is always initialized, regardless of the value of \
GUIenabled. This may change in future versions of Qt.</p> </blockquote>
<p style="padding: 0;text-rendering: inherit;margin: 0;line-height: \
inherit;white-space: inherit;">So it's perhaps rather a statement in \
KApplicationPrivate::init() which causes this?<br style="padding: 0;text-rendering: \
inherit;margin: 0;line-height: inherit;white-space: normal;" /> There aren't too many \
depending on GUIEnabled ... ;-)</p></pre>  </blockquote>




 <p>On September 25th, 2014, 9:50 nachm. UTC, <b>René J.V. Bertin</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;"><p style="padding: \
0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: \
inherit;">Thiagos?</p> <p style="padding: 0;text-rendering: inherit;margin: \
0;line-height: inherit;white-space: inherit;">The menubar/Dock "item stuff" is the \
result of <code style="text-rendering: inherit;color: #4444cc;padding: 0;white-space: \
normal;margin: 0;line-height: inherit;">qt_mac_loadMenuNib</code> in <code \
style="text-rendering: inherit;color: #4444cc;padding: 0;white-space: normal;margin: \
0;line-height: inherit;">qapplication_mac.mm</code>, which is called when <code \
style="text-rendering: inherit;color: #4444cc;padding: 0;white-space: normal;margin: \
0;line-height: inherit;">!QApplication::testAttribute(Qt::AA_MacPluginApplication)</code>. \
Setting <code style="text-rendering: inherit;color: #4444cc;padding: 0;white-space: \
normal;margin: 0;line-height: inherit;">GUIenabled=false</code> has that effect, \
ultimately.</p></pre>  </blockquote>








</blockquote>

<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;"><blockquote \
style="text-rendering: inherit;padding: 0 0 0 1em;border-left: 1px solid \
#bbb;white-space: normal;margin: 0 0 0 0.5em;line-height: inherit;"> <p \
style="padding: 0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: \
inherit;">Thiagos?</p> </blockquote>
<p style="padding: 0;text-rendering: inherit;margin: 0;line-height: \
inherit;white-space: inherit;">By mail:<br style="padding: 0;text-rendering: \
inherit;margin: 0;line-height: inherit;white-space: normal;" /> \
http://lists.kde.org/?l=kde-core-devel&amp;m=141166670217317&amp;w=2</p> <blockquote \
style="text-rendering: inherit;padding: 0 0 0 1em;border-left: 1px solid \
#bbb;white-space: normal;margin: 0 0 0 0.5em;line-height: inherit;"> <p \
style="padding: 0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: \
inherit;">result of qt_mac_loadMenuNib in qapplication_mac.mm</p> </blockquote>
<p style="padding: 0;text-rendering: inherit;margin: 0;line-height: \
inherit;white-space: inherit;">Ok, so the API doc lied to me ;-)<br style="padding: \
0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: normal;" /> \
Since the attributes are static, you could simply set it before creating the \
application in the relevant main funcs, could you?<br style="padding: \
0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: normal;" /> \
(Though i actually don't see it set anywhere - but it's late and i'm \
tired...)</p></pre> <br />










<p>- Thomas</p>


<br />
<p>On September 25th, 2014, 1:32 nachm. UTC, René J.V. Bertin wrote:</p>









<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="12" style="border: \
1px #888a85 solid; border-radius: 6px; -moz-border-radius: 6px; \
-webkit-border-radius: 6px;">  <tr>
  <td>

<div>Review request for KDE Software on Mac OS X and kdelibs.</div>
<div>By René J.V. Bertin.</div>


<p style="color: grey;"><i>Updated Sept. 25, 2014, 1:32 nachm.</i></p>









<div style="margin-top: 1.5em;">
 <b style="color: #575012; font-size: 10pt;">Repository: </b>
kdelibs
</div>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </h1>
 <table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" \
style="border: 1px solid #b8b5a0">  <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: \
-moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: \
break-word;"><p style="padding: 0;text-rendering: inherit;margin: 0;line-height: \
inherit;white-space: inherit;">Applications can be defined in their CMake file as \
being <code style="text-rendering: inherit;color: #4444cc;padding: 0;white-space: \
normal;margin: 0;line-height: inherit;">NOGUI</code>, but until now this has had very \
limited effect. Especially on OS X, those applications can still construct a minimal \
GUI and thus have "visual presence" in the Dock and application switcher (and have a \
menubar as well).</p> <p style="padding: 0;text-rendering: inherit;margin: \
0;line-height: inherit;white-space: inherit;">This patch proposes to define a \
preprocessor token, <code style="text-rendering: inherit;color: #4444cc;padding: \
0;white-space: normal;margin: 0;line-height: inherit;">KDE_WITHOUT_GUI</code>, for \
those targets, and uses that token to set the default value for the <code \
style="text-rendering: inherit;color: #4444cc;padding: 0;white-space: normal;margin: \
0;line-height: inherit;">GUIenabled</code> option of the <code style="text-rendering: \
inherit;color: #4444cc;padding: 0;white-space: normal;margin: 0;line-height: \
inherit;">KApplication</code> and <code style="text-rendering: inherit;color: \
#4444cc;padding: 0;white-space: normal;margin: 0;line-height: \
inherit;">KUniqueApplication</code> classes.</p> <p style="padding: 0;text-rendering: \
inherit;margin: 0;line-height: inherit;white-space: inherit;">This could potentially \
be combined on OS X with the CoreFoundation call that turns a running application \
into an "agent" (see https://git.reviewboard.kde.org/r/120354).</p></pre>  </td>
 </tr>
</table>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Testing </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: \
1px solid #b8b5a0">  <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: \
-moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: \
break-word;"><p style="padding: 0;text-rendering: inherit;margin: 0;line-height: \
inherit;white-space: inherit;">On OS X 10.6.8 with kdelibs 4.14.1 (git/kde4.14), \
rebuilt kdelibs, kde-workspace, kde-runtime, kde-baseapps, kdepim-runtime and \
nepomuk-core.<br style="padding: 0;text-rendering: inherit;margin: 0;line-height: \
inherit;white-space: normal;" /> If the documentation I read is correct, the <code \
style="text-rendering: inherit;color: #4444cc;padding: 0;white-space: normal;margin: \
0;line-height: inherit;">GUIenabled</code> switch has no effect on Linux, so this \
patch shouldn't have any either on that OS.</p></pre>  </td>
 </tr>
</table>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">

 <li>cmake/modules/KDE4Macros.cmake <span style="color: grey">(073d726)</span></li>

 <li>kdeui/kernel/kapplication.h <span style="color: grey">(fa2ab26)</span></li>

 <li>kdeui/kernel/kapplication.cpp <span style="color: grey">(b093034)</span></li>

 <li>kdeui/kernel/kuniqueapplication.h <span style="color: \
grey">(e05dcd7)</span></li>

</ul>

<p><a href="https://git.reviewboard.kde.org/r/120363/diff/" style="margin-left: \
3em;">View Diff</a></p>






  </td>
 </tr>
</table>








  </div>
 </body>
</html>


--===============8258688310228018905==--


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic