unsubscribe<div class="gmail_extra"><br><br><div class="gmail_quote">On 14 December 2012 08:30,  <span dir="ltr"><<a href="mailto:kde-bindings-request@kde.org" target="_blank">kde-bindings-request@kde.org</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Send Kde-bindings mailing list submissions to<br>
        <a href="mailto:kde-bindings@kde.org">kde-bindings@kde.org</a><br>
<br>
To subscribe or unsubscribe via the World Wide Web, visit<br>
        <a href="https://mail.kde.org/mailman/listinfo/kde-bindings" target="_blank">https://mail.kde.org/mailman/listinfo/kde-bindings</a><br>
or, via email, send a message with subject or body 'help' to<br>
        <a href="mailto:kde-bindings-request@kde.org">kde-bindings-request@kde.org</a><br>
<br>
You can reach the person managing the list at<br>
        <a href="mailto:kde-bindings-owner@kde.org">kde-bindings-owner@kde.org</a><br>
<br>
When replying, please edit your Subject line so it is more specific<br>
than "Re: Contents of Kde-bindings digest..."<br>
<br>Today's Topics:<br>
<br>
   1. Re: Qyoto: Patch v2: Translate obvious getters    into<br>
      properties or "Get" methods (Crowell, Brian)<br>
<br><br>---------- Forwarded message ----------<br>From: "Crowell, Brian" <<a href="mailto:BCrowell@barbnet.com">BCrowell@barbnet.com</a>><br>To: Dimitar Dobrev <<a href="mailto:dpldobrev@yahoo.com">dpldobrev@yahoo.com</a>>, "KDE bindings for other programming languages" <<a href="mailto:kde-bindings@kde.org">kde-bindings@kde.org</a>><br>
Cc: <br>Date: Thu, 13 Dec 2012 21:30:15 +0000<br>Subject: Re: [Kde-bindings] Qyoto: Patch v2: Translate obvious getters into        properties or "Get" methods<br>





<div lang="EN-US" link="blue" vlink="purple">
<div>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">On address: I’m easy, actually, but I haven’t gotten out of the mode of “addressing-people-by-their-first-name-is-presumptive-on-my-part.” First names it is.<u></u><u></u></span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">On uics: HasHeightForWidth() is part of the “special” code in cswriteinitialization.cpp. I’ll try to correct a few things in there. I’m going to fix an issue
 with properties on interfaces before I issue another version of the patch. I’m mainly offering it for review and feedback (which so far has worked); I’m not sure at what point you’d consider it right to commit it.<u></u><u></u></span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">--Brian<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<div style="border:none;border-left:solid blue 1.5pt;padding:0in 0in 0in 4.0pt">
<div>
<div style="border:none;border-top:solid #b5c4df 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">From:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> <a href="mailto:kde-bindings-bounces@kde.org" target="_blank">kde-bindings-bounces@kde.org</a> [mailto:<a href="mailto:kde-bindings-bounces@kde.org" target="_blank">kde-bindings-bounces@kde.org</a>]
<b>On Behalf Of </b>Dimitar Dobrev<br>
<b>Sent:</b> Thursday, December 13, 2012 3:17 PM<br>
<b>To:</b> KDE bindings<br>
<b>Subject:</b> Re: [Kde-bindings] Qyoto: Patch v2: Translate obvious getters into properties or "Get" methods<u></u><u></u></span></p>
</div>
</div>
<p class="MsoNormal"><u></u> <u></u></p>
<div>
<div>
<p class="MsoNormal" style="background:white"><span style><br>
<span>    This is better, however, there is another problem that had been "hidden" (that is, the compiler stopped there) by the Model issue: some of the code generated by uics is no longer valid, the "HasHeightForWidth" method in particular. Sorry
 about me not noticing earlier but I'd like to ask you to update uics as well. This is the only method I've found so if there are others, I'll fix them myself. On the other hand, the properties are OK, so I'll push them. Whenever you're ready with uics, I'll
 push the Get_ part too.</span><u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span><span style>    By the way, you didn't say what you think about the form of address. :)</span></span><span style><u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style><u></u> <u></u></span></p>
</div>
<div>
<p class="MsoNormal" style="background:white"><span><span style>    Dimitar</span></span><span style><u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal" style="background:white"><span style><u></u> <u></u></span></p>
</div>
<div>
<div>
<div>
<div class="MsoNormal" align="center" style="text-align:center;background:white">
<span style="font-size:10.0pt;font-family:"Arial","sans-serif"">
<hr size="1" width="100%" align="center">
</span></div>
<p class="MsoNormal" style="background:white"><b><span style="font-size:10.0pt;font-family:"Arial","sans-serif"">From:</span></b><span style="font-size:10.0pt;font-family:"Arial","sans-serif""> "Crowell, Brian" <<a href="mailto:BCrowell@barbnet.com" target="_blank">BCrowell@barbnet.com</a>><br>

<b>To:</b> Dimitar Dobrev <<a href="mailto:dpldobrev@yahoo.com" target="_blank">dpldobrev@yahoo.com</a>>; KDE bindings for other programming languages <<a href="mailto:kde-bindings@kde.org" target="_blank">kde-bindings@kde.org</a>>
<br>
<b>Sent:</b> Thursday, December 13, 2012 10:47 PM<br>
<b>Subject:</b> RE: [Kde-bindings] Qyoto: Patch v2: Translate obvious getters into properties or "Get" methods</span><span style><u></u><u></u></span></p>
</div>
<p class="MsoNormal" style="background:white"><span style><u></u> <u></u></span></p>
<div>
<div>
<div>
<div>
<p class="MsoNormal" style="background:white"><span style="font-size:11.0pt;color:#1f497d">Version 2 then, with more properties, and fix for the Model issue.</span><span style><u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal" style="background:white"><span style="font-size:11.0pt;color:#1f497d"> </span><span style><u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal" style="background:white"><span style="font-size:11.0pt;color:#1f497d">I’d be uncomfortable blacklisting methods. If List<QWidget> QWidget.Children() remains a method, nobody gets hurt, but if bool QMovie.JumpToNextFrame() becomes a property,
 chaos happens. There is one pattern that could be exploited: methods starting with nouns or adjectives like “Widget,” “Width,” “Window,” “File,” “Root,” “Physical,” and “Temp” are almost certainly properties, but so far only the “File” prefix has more than
 two entries in my list.</span><span style><u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal" style="background:white"><span style="font-size:11.0pt;color:#1f497d"> </span><span style><u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal" style="background:white"><span style="font-size:11.0pt;color:#1f497d">--Brian</span><span style><u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal" style="background:white"><span style="font-size:11.0pt;color:#1f497d"> </span><span style><u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal" style="background:white"><span style="font-size:11.0pt;color:#1f497d"> </span><span style><u></u><u></u></span></p>
</div>
<div style="border:none;border-left:solid blue 1.5pt;padding:0in 0in 0in 4.0pt">
<div>
<div style="border:none;border-top:solid #b5c4df 1.0pt;padding:3.0pt 0in 0in 0in">
<div>
<p class="MsoNormal" style="background:white"><b><span style="font-size:10.0pt">From:</span></b><span style="font-size:10.0pt">
<a href="mailto:kde-bindings-bounces@kde.org" target="_blank">kde-bindings-bounces@kde.org</a> [<a href="mailto:kde-bindings-bounces@kde.org" target="_blank">mailto:kde-bindings-bounces@kde.org</a>]
<b>On Behalf Of </b>Dimitar Dobrev<br>
<b>Sent:</b> Thursday, December 13, 2012 1:15 PM<br>
<b>To:</b> KDE bindings for other programming languages<br>
<b>Subject:</b> Re: [Kde-bindings] Qyoto: Patch v1: Translate obvious getters into properties or "Get" methods</span><span style><u></u><u></u></span></p>
</div>
</div>
</div>
<div>
<p class="MsoNormal" style="background:white"><span style> <u></u><u></u></span></p>
</div>
<div>
<div>
<p class="MsoNormal" style="background:white"><span><span style>   
</span></span><span style><u></u><u></u></span></p>
</div>
<div>
<div>
<p class="MsoNormal" style="background:white"><span><span style>    Mr. Crowell,</span></span><span style><u></u><u></u></span></p>
</div>
</div>
<div>
<div>
<p class="MsoNormal" style="background:white"><span><span style>   
</span></span><span style><u></u><u></u></span></p>
</div>
</div>
<div>
<div>
<p class="MsoNormal" style="background:white"><span><span style>    Thanks for the patch, it looks n</span></span><span style>ice. I'll discuss it in a while. First, I'd like to point out that there is no
 need for us here in open source communities to be that formal. :) If you agree with me, you may call me "Dimitar" and in turn I would call you "Brian". However, if you do prefer an official form of address, that's fine by me.<u></u><u></u></span></p>

</div>
</div>
<div>
<div>
<p class="MsoNormal" style="background:white"><span><span style>    About your patch: it looks very good, and I like how you reused the method for generating a property instead of writing your own. :) However, I have two
 remarks, a regression and a suggestion:</span></span><span style><u></u><u></u></span></p>
</div>
</div>
<div>
<div>
<p class="MsoNormal" style="background:white"><span><span style>    1. QComboBox.Model used to be a read-write property, now it's read only. Could you please change your code so that it remains read-write? Also, if possible,
 check for other such cases because this is simply one I found, it doesn't mean there aren't more;</span></span><span style><u></u><u></u></span></p>
</div>
</div>
<div>
<div>
<p class="MsoNormal" style="background:white"><span><span style>    2.
</span></span><span style>I'm wondering if it would be better to have something like a list of commonly used in API-s verbs, and then if the method starts with has or is or is a single word (this can be checked by casing) and this single word
 is not a verb, the method should be generated as a property. The thing is that your way you have to look for properties all over the huge Qt API, and that with each Qt version (for example, Qt 5 is coming very soon). Of course, the verb approach may actually
 turn out to be worse because there may be way too many verbs to enumerate. So this is simply a suggestion for you to think about if you like.<br>
<span>    </span><u></u><u></u></span></p>
</div>
</div>
<div>
<div>
<p class="MsoNormal" style="background:white"><span><span style>    Dimitar</span></span><span style><u></u><u></u></span></p>
</div>
</div>
<div>
<div>
<p class="MsoNormal" style="background:white"><span style> <u></u><u></u></span></p>
</div>
</div>
<div>
<div>
<div>
<div class="MsoNormal" align="center" style="text-align:center;background:white">
<span style="font-size:10.0pt">
<hr size="1" width="100%" align="center">
</span></div>
<div>
<p class="MsoNormal" style="background:white"><b><span style="font-size:10.0pt">From:</span></b><span style="font-size:10.0pt"> "Crowell, Brian" <<a href="mailto:BCrowell@barbnet.com" target="_blank">BCrowell@barbnet.com</a>><br>

<b>To:</b> KDE bindings for other programming languages <<a href="mailto:kde-bindings@kde.org" target="_blank">kde-bindings@kde.org</a>>
<br>
<b>Sent:</b> Thursday, December 13, 2012 8:23 PM<br>
<b>Subject:</b> [Kde-bindings] Qyoto: Patch v1: Translate obvious getters into properties or "Get" methods</span><span style><u></u><u></u></span></p>
</div>
</div>
<div style="margin-bottom:12.0pt">
<p class="MsoNormal" style="margin-bottom:12.0pt;background:white"><span style><br>
As discussed with Mr. Dobrev, this patch finds methods with certain names and signatures and translates them into properties. This covers "Is" and "Has" properties along with a specified list of noun phrases. Getter methods that take arguments are renamed "Get"
 (Sibling(int row, int column) becomes GetSibling(int row, int column)).<br>
<br>
The list of property names is incomplete. I'll add more as I find them.<br>
<br>
--Brian<br>
_______________________________________________<br>
Kde-bindings mailing list<br>
<a href="mailto:Kde-bindings@kde.org" target="_blank">Kde-bindings@kde.org</a><br>
<a href="https://mail.kde.org/mailman/listinfo/kde-bindings" target="_blank">https://mail.kde.org/mailman/listinfo/kde-bindings</a><u></u><u></u></span></p>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<p class="MsoNormal" style="margin-bottom:12.0pt;background:white"><span style><u></u> <u></u></span></p>
</div>
</div>
</div>
</div>
</div>
</div>

<br>_______________________________________________<br>
Kde-bindings mailing list<br>
<a href="mailto:Kde-bindings@kde.org">Kde-bindings@kde.org</a><br>
<a href="https://mail.kde.org/mailman/listinfo/kde-bindings" target="_blank">https://mail.kde.org/mailman/listinfo/kde-bindings</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br>Marc Jackson<br>Agile Developer/DevOps - Unix/Linux/Windoze<br>Mobile: +61 468 321467<br>
</div>