<br><br><div class="gmail_quote">On Tue, Jul 21, 2009 at 3:28 PM, Diego Casella ([Po]lentino) <span dir="ltr">&lt;<a href="mailto:polentino911@gmail.com">polentino911@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br><div class="gmail_quote"><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div class="gmail_quote">On Mon, Jul 20, 2009 at 7:29 PM, Yuen Hoe Lim <span dir="ltr">&lt;<a href="mailto:yuenhoe86@gmail.com" target="_blank">yuenhoe86@gmail.com</a>&gt;</span> wrote:<br>

<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Yep, it doesn&#39;t seem to accept regular expressions - but a string<br>
containing every permitted character..<br>
<br>
<a href="http://api.kde.org/4.x-api/kdelibs-apidocs/kdeui/html/classKRestrictedLine.html#f30d883fc60f67be39e8ffa039842cd6" target="_blank">http://api.kde.org/4.x-api/kdelibs-apidocs/kdeui/html/classKRestrictedLine.html#f30d883fc60f67be39e8ffa039842cd6</a><br>



<br>
I&#39;ve tried, and it actually does allow me to type every character in<br>
the expression (like &#39;[&#39; and &#39;$&#39;) =/ It doesn&#39;t seem like a pretty<br>
thing to do &#39;qwertyQWERTY012345etcetc&#39; so maybe we could try a regular<br>
KLineEdit and do some form of validation?</blockquote><div><br>For that we&#39;ve to find out what characters make a valid project name (if there is a restriction as such, say, on name of a Plasmoid).<br>Help wanted from others. Guys?<br>


</div></div></blockquote><div><br>Sorry but yesterday morning I was @ university, and in the evening I compiled KDE 4.4 =P</div></div></blockquote><div> </div><div>You mean trunk, right? ;) <br></div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="gmail_quote"><div><br>By the way today I had a look to the code, fixed ( seems it works fine, however tell me if something is wrong ) and committed.<br>
The key point ( imo ) is that by typing:<br><br>

<p style="margin: 0px 0px 0px 40px; text-indent: 0px;">QRegExpValidator *pluginname_validator = new QRegExpValidator(ui-&gt;projectName);</p><p style="margin: 0px 0px 0px 40px; text-indent: 0px;"><br></p>you are simply telling to pluginname_validator &quot;Hey, your parent is a QObject reference called projectName&quot;; but also a QWidget<br>

could be a valid parent, or a QString. It doesn&#39;t know how to parse a regular expression with a given QObject reference, that&#39;s up to us.<br>However, I removed all QRegExp* statement from setupWidgets(), and connected signals from 
projectName to a slot I created to<br>parse the text and find unwanted characters. Let me know if it works !</div></div></blockquote><div><br>Yep, it works as expected. Also, I think now KRestrictedLine is not necessary now. So I&#39;ve replaced it with KLineEdit to keep things simple.<br>
<br></div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div class="gmail_quote"><div><br><br>P.S.: after upgrading to KDE4.4, PlasMate menu has changed: now it shows entries like &quot;Game&quot;, &quot;Edit&quot;, &quot;Move&quot;, &quot;View&quot;, &quot;Go&quot;,<br>

and &quot;Bookmarks&quot;, &quot;Tools&quot; O.o</div></div></blockquote><div> </div><div>No, that doesn&#39;t happen here. Maybe some problem with your installation.<br> </div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="gmail_quote"><div><br>The same problem appears with KTorrent.<br></div></div>
<br>_______________________________________________<br>
Plasma-devel mailing list<br>
<a href="mailto:Plasma-devel@kde.org">Plasma-devel@kde.org</a><br>
<a href="https://mail.kde.org/mailman/listinfo/plasma-devel" target="_blank">https://mail.kde.org/mailman/listinfo/plasma-devel</a><br>
<br></blockquote></div><br><br clear="all"><br>-- <br>Shantanu Tushar    (UTC +0530)<br><a href="http://www.shantanutushar.com">http://www.shantanutushar.com</a><br>