Plasma-devel Digest, Vol 13, Issue 55
Shantanu Tushar Jha
jhahoneyk at gmail.com
Tue Jul 21 15:29:49 CEST 2009
On Tue, Jul 21, 2009 at 3:28 PM, Diego Casella ([Po]lentino) <
polentino911 at gmail.com> wrote:
> On Mon, Jul 20, 2009 at 7:29 PM, Yuen Hoe Lim <yuenhoe86 at gmail.com> wrote:
>>> Yep, it doesn't seem to accept regular expressions - but a string
>>> containing every permitted character..
>>> I've tried, and it actually does allow me to type every character in
>>> the expression (like '[' and '$') =/ It doesn't seem like a pretty
>>> thing to do 'qwertyQWERTY012345etcetc' so maybe we could try a regular
>>> KLineEdit and do some form of validation?
>> For that we've to find out what characters make a valid project name (if
>> there is a restriction as such, say, on name of a Plasmoid).
>> Help wanted from others. Guys?
> Sorry but yesterday morning I was @ university, and in the evening I
> compiled KDE 4.4 =P
You mean trunk, right? ;)
> 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.
> The key point ( imo ) is that by typing:
> QRegExpValidator *pluginname_validator = new
> you are simply telling to pluginname_validator "Hey, your parent is a
> QObject reference called projectName"; but also a QWidget
> could be a valid parent, or a QString. It doesn't know how to parse a
> regular expression with a given QObject reference, that's up to us.
> However, I removed all QRegExp* statement from setupWidgets(), and
> connected signals from projectName to a slot I created to
> parse the text and find unwanted characters. Let me know if it works !
Yep, it works as expected. Also, I think now KRestrictedLine is not
necessary now. So I've replaced it with KLineEdit to keep things simple.
> P.S.: after upgrading to KDE4.4, PlasMate menu has changed: now it shows
> entries like "Game", "Edit", "Move", "View", "Go",
> and "Bookmarks", "Tools" O.o
No, that doesn't happen here. Maybe some problem with your installation.
> The same problem appears with KTorrent.
> Plasma-devel mailing list
> Plasma-devel at kde.org
Shantanu Tushar (UTC +0530)
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Plasma-devel