Re: [Lazarus] Accents in IDE and my apps

2013-07-15 Thread Éderson Cássio

Em 13-07-2013 02:13, Mattias Gaertner escreveu:

On Fri, 12 Jul 2013 15:36:26 -0700 (PDT)
Éderson Cássio ederson_cas...@yahoo.com.br wrote:


[...]
It was a problem for which I could produce a solution in the LCL code, but 
Mattias Gaertner said me the problem doesn't occur on all systems. Well, I 
found one situation when the problem occurs, on my system.

It's not only a my system problem, it's a problem in the way the GTK2 Lazarus widgetset interacts 
with some systems (including mine). I say that because other GTK2 applications have a normal behavior, even 
Lazarus applications when my system language is English. Maybe an if would solve the 
problem; I just want to keep talking to someone who can guide me in the LCL changes without causing 
disasters. Mattias gave me an advice (thanks!), and I have found a new direction.

It is possible to add the changes via an IFDEF. For example:

{$IfDef EnableGtk2AccentKeyMod2}
// new solution ...
{$Else}
// old solution ...
{$EndIf}

Then you can ask people to test this by adding a
-dEnableGtk2AccentKeyMod2 to their IDE options.

Can you create a patch for this?

Mattias

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Mattias, thanks for your help.
I don't know how I can create a patch... everything I know is that I 
must download the sources from SVN, but I'm raw about these kind of task 
(ashamed...)

If I give some simple instructions, can you or somebody create it?

In _*lcl/interfaces/gtk2/gtk2proc.inc*_, line 2278, we have:

CheckDeadKey;


We just need to do the solution you gave (I created a new name for the 
directive):


{$IfDef GTK2LatinAccents}
   gtk_im_context_filter_keypress(im_context, AEvent);
{$Else}
   CheckDeadKey;
{$EndIf}


Thanks, I hope it will be useful for some people asking in the forums!

Éderson


--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Accents in IDE and my apps

2013-07-12 Thread Éderson Cássio
I wrote on this thread because I'd like to help to improve Lazarus code as I 
find problems with it.

It was a problem for which I could produce a solution in the LCL code, but 
Mattias Gaertner said me the problem doesn't occur on all systems. Well, I 
found one situation when the problem occurs, on my system. 

It's not only a my system problem, it's a problem in the way the GTK2 Lazarus 
widgetset interacts with some systems (including mine). I say that because 
other GTK2 applications have a normal behavior, even Lazarus applications when 
my system language is English. Maybe an if would solve the problem; I just 
want to keep talking to someone who can guide me in the LCL changes without 
causing disasters. Mattias gave me an advice (thanks!), and I have found a new 
direction. 



 De: waldo kitty wkitt...@windstream.net
Para: lazarus@lists.lazarus.freepascal.org 
Enviadas: Sexta-feira, 12 de Julho de 2013 10:38
Assunto: Re: [Lazarus] Accents in IDE and my apps
 

On 7/12/2013 00:05, Éderson Cássio wrote:
 Hello, guys.
 I've just found that the duplicated accents problem in GTK2 only occurs when I
 configure my system language to Brazilian Portuguese.
 The problem happens with any keyboard layout, just like the Brazilian layout 
 and
 even with the US International.
 Any ideas?
 Thanks
 Éderson Cássio - Brazil

other than thoughts about your thread hijacking attempt? nope... no ideas at 
all... perhaps you meant to post this another thread specific to your keyboard 
problem topic? perhaps you meant to start a new thread? ;) ;) ;)

-- 
NOTE: No off-list assistance is given without prior approval.
       Please keep mailing list traffic on the list unless
       private contact is specifically requested and granted.

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Accents in IDE and my apps

2013-07-12 Thread Éderson Cássio

Em 12-07-2013 22:31, waldo kitty escreveu:

On 7/12/2013 18:36, Éderson Cássio wrote:
I wrote on this thread because I'd like to help to improve Lazarus 
code as I

find problems with it.


i understand that but your addition has nothing to do with comment 
properties in TObject or TComponent :/


the only reason i saw your portion was because i have not marked this 
thread as ignore or all caught up... many others will not see your 
posts because of this...


I am new to this list, the only way I know to use it is sending a 
message to lazarus@lists.lazarus.freepascal.org. How do I know what 
thread the message is going to, who is reading, who is not reading...?



--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


[Lazarus] Accents in IDE and my apps

2013-07-11 Thread Éderson Cássio
Hello, guys.
I've just found that the duplicated accents problem in GTK2 only occurs when I 
configure my system language to Brazilian Portuguese.
The problem happens with any keyboard layout, just like the Brazilian layout 
and even with the US International.
Any ideas?
Thanks
Éderson Cássio - Brazil--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


[Lazarus] Accents in IDE and my apps

2013-07-07 Thread Éderson Cássio
When I type accented letters in the IDE or in my forms, they appear 
duplicated: áá êê íí õõ üü ...


Searching the bugtracker, I found 
this:http://bugs.freepascal.org/view.php?id=15688


It seems to be a GTK2 problem, in the CheckDeadKey procedure 
(lcl/interfaces/gtk2/gtk2proc.inc).


I tried to comment out such code and replace the call by a single call 
to gtk_im_context_filter_keypress. It solved the duplication problem but 
I can't type an accent key (a dead key) in one control, and after type 
the letter in other control. It's not a big problem to me, but it's a 
pattern in applications behavior.


Does anybody know how can I contact someone in the development  team and 
talk about this? I'd like to help to improve the GTK2 support, but I'm a 
newbie about this...
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Accents in IDE and my apps

2013-07-07 Thread Éderson Cássio

Em 07-07-2013 15:54, Mattias Gaertner escreveu:

On Sun, 07 Jul 2013 15:22:53 -0300
Éderson Cássio ederson_cas...@yahoo.com.br wrote:


When I type accented letters in the IDE or in my forms, they appear
duplicated: áá êê íí õõ üü ...

Searching the bugtracker, I found
this:http://bugs.freepascal.org/view.php?id=15688

It seems to be a GTK2 problem, in the CheckDeadKey procedure
(lcl/interfaces/gtk2/gtk2proc.inc).

I tried to comment out such code and replace the call by a single call
to gtk_im_context_filter_keypress. It solved the duplication problem but
I can't type an accent key (a dead key) in one control, and after type
the letter in other control. It's not a big problem to me, but it's a
pattern in applications behavior.

Does anybody know how can I contact someone in the development  team and
talk about this? I'd like to help to improve the GTK2 support, but I'm a
newbie about this...

Looking at the bug thread it seems that there is no solution yet that
works on all systems, right?


Mattias

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Hello, Mattias! I don't know... I have no problems with native win32 
widgetset. Did anybody test GTK2 widgetset in Windows? Maybe I should do 
it, just to see its behavior, although I won't neet it.


--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Accents in IDE and my apps

2013-07-07 Thread Éderson Cássio

Em 07-07-2013 21:40, Éderson Cássio escreveu:

Em 07-07-2013 15:54, Mattias Gaertner escreveu:

On Sun, 07 Jul 2013 15:22:53 -0300
Éderson Cássio ederson_cas...@yahoo.com.br wrote:


When I type accented letters in the IDE or in my forms, they appear
duplicated: áá êê íí õõ üü ...

Searching the bugtracker, I found
this:http://bugs.freepascal.org/view.php?id=15688

It seems to be a GTK2 problem, in the CheckDeadKey procedure
(lcl/interfaces/gtk2/gtk2proc.inc).

I tried to comment out such code and replace the call by a single call
to gtk_im_context_filter_keypress. It solved the duplication problem 
but

I can't type an accent key (a dead key) in one control, and after type
the letter in other control. It's not a big problem to me, but it's a
pattern in applications behavior.

Does anybody know how can I contact someone in the development  team 
and
talk about this? I'd like to help to improve the GTK2 support, but 
I'm a

newbie about this...

Looking at the bug thread it seems that there is no solution yet that
works on all systems, right?


Mattias

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Hello, Mattias! I don't know... I have no problems with native win32 
widgetset. Did anybody test GTK2 widgetset in Windows? Maybe I should 
do it, just to see its behavior, although I won't neet it.


--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Done, I have just tested GTK2 in Windows (XP). The letter duplication 
doesn't happen. If I type an accent (a dead key) in one control, and 
move the focus to other control, the first loses the accent. It's a 
good behavior (to me). I made the change in gtk2proc.inc and the 
behavior remains the same.


In Linux, with the original gtk2proc.inc, I have the letter duplication 
problem. Changing the gtk2 binding code, I can type accents fine. But, 
if I type a dead key in one control and move to other, the accent 
stays in the first control, waiting for the letter. I don't see it as 
a big problem.


The changes I made:
- Remove the CheckDeadKey procedure
- Replace its call by a: *gtk_im_context_filter_keypress(im_context, 
AEvent);**

*
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus