Re: [Lazarus] 1 keypress gives multiple letters ONLY in program written in Lazarus in raspbian jessie Pi 2

2016-04-11 Thread Michael Thompson
On 12 April 2016 at 02:51, Giuliano Colla 
wrote:
>
> I took the liberty of editing the Wiki entry, using all the information I
> have.
>
> Please feel free to adjust as you deem proper.
>
>
Nice work.  More technical than I was capable of :-)

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


Re: [Lazarus] 1 keypress gives multiple letters ONLY in program written in Lazarus in raspbian jessie Pi 2

2016-04-11 Thread Giuliano Colla

Il 10/04/2016 21:16, Michael Thompson ha scritto:

I know this issue is resolved, but I've just stumbled across this:

http://wiki.lazarus.freepascal.org/Lazarus_Faq#Typing_under_Ubuntu_in_edit_fields_generate_duplicate_letters

We'll need to change Ubuntu now to Linux in general, but before I do 
that: Giuliano: Do you know if any of the steps listed here would have 
helped?  If not, can you let me know how you disabled the Input 
Manager, and I'll update the wiki accordinly.


I took the liberty of editing the Wiki entry, using all the information 
I have.


Please feel free to adjust as you deem proper.

Giuliano


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


Re: [Lazarus] 1 keypress gives multiple letters ONLY in program written in Lazarus in raspbian jessie Pi 2

2016-04-10 Thread

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


Re: [Lazarus] 1 keypress gives multiple letters ONLY in program written in Lazarus in raspbian jessie Pi 2

2016-04-10 Thread Giuliano Colla

Il 10/04/2016 21:16, Michael Thompson ha scritto:
Giuliano: Do you know if any of the steps listed here would have 
helped?  If not, can you let me know how you disabled the Input 
Manager, and I'll update the wiki accordinly.


I have only hearsay knowledge, from this list complaints, and from some 
search on Internet I made because of that.
I'm not using Ubuntu or any other Debian/Ubuntu derived distro, and I do 
not have a direct experience.
I'm using the Red Hat distros line (RHEL, Fedora and CentOs) and I did 
never stumble into a similar problem.
Therefore take what I say with appropriate caution (and most of all do 
not use it in tribunal .)


However the problem appears to arise from the Keyboard Input Methods 
being enabled by default, even when no actual Input Method is assigned. 
From what I gathered, this problem popped up as with Ubuntu 11, and 
should be related to Gnome Desktop.
Previous versions were immune, but I can't tell if it was because ibus 
service wasn't used, or because Keyboard Input Methods were not enabled.


However the full picture is the following:

Input Methods are those methods which allow to accommodate languages 
with ideographic symbols which cannot possibly fit in a normal sized 
keyboard, such as Chinese.


Those user need also to enter Latin alphabet characters for system 
commands, therefore a keyboard shortcut is required to toggle on and off 
the Input Method.


The standard shortcut to toggle Input Method is ctrl-space, which 
happens also to be the standard code completion shortcut of Lazarus. 
This alone can be a cause of troubles.
Moreover, if the Input Methods are enabled, but no actual Input method 
is defined, toggling may lead to weird results, such as characters being 
entered twice, characters being lost etc.


The steps to overcome the problem are:

1) If Input Methods are required (e.g. a Chinese user), one of the two 
shortcuts must be changed.


2) If no Input Methods are required, they should be disabled. No general 
rule can be given on how to do that, because each Desktop environment 
does it its way. Gnome provides in System Settings an "Input Method" 
entry. KDE provides an Icon in the systray, but only if a specific Input 
Method package has been installed, otherwise the Input Methods are disabled.


3) If no Input Methods are required and the user is unable to disable 
the Input Methods, one can simply stop the ibus service, whose only 
purpose appears to be that of supporting the Input Methds. Again, how to 
do that is strongly system dependent.


I can't say if the steps indicated in the Wiki page are useful in 
general. From what I read GTK_IM_MODULE=gtk-im-context-simple
should be a better choice than gtk-im-context-xim which enables the old 
XIM (X Input Method) framework.
But it would require some testing in Ubuntu or Ubuntu siblings, and with 
different locale.


That's all I can tell.

Giuliano


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


Re: [Lazarus] 1 keypress gives multiple letters ONLY in program written in Lazarus in raspbian jessie Pi 2

2016-04-10 Thread Michael Thompson
I know this issue is resolved, but I've just stumbled across this:

http://wiki.lazarus.freepascal.org/Lazarus_Faq#Typing_under_Ubuntu_in_edit_fields_generate_duplicate_letters

We'll need to change Ubuntu now to Linux in general, but before I do that:
Giuliano: Do you know if any of the steps listed here would have helped?
If not, can you let me know how you disabled the Input Manager, and I'll
update the wiki accordinly.

Thanks

Mike

On 10 April 2016 at 23:02, Dennis  wrote:

>
>
> Giuliano Colla wrote:
>
>> Il 09/04/2016 18:49, JuuS ha scritto:
>>
>>> Personally I had quite a fight with ibus and I finally removed it from
>>> my system with no ill effects. It is mostly used AFAIK with asian
>>> "alphabets".
>>>
>>
>> There must be some problem with ibus/input methods in the Debian line,
>> because it would appear that more or less all recent Debian based distro's
>> (Ubuntu, Raspbian, ect.) show some weird keyboard behaviour, which wasn't
>> present in the previous versions.
>>
>> Red Hat line (Red Hat, Fedora, CentOs etc.) appears to be immune from
>> this problem. I didn't find any complaint of this type on Internet, and
>> when I have been forced to enable keyboard input methods to support
>> Chinese, nothing strange happened (except when if you forget to switch back
>> to English ;-) ...)
>>
>> Maybe someone with a good knowledge of both worlds could find where the
>> problem is?
>>
>> Giuliano
>>
>> I turned off Raspbian's Input Method and the problem is gone now.
> thanks for everyone's tips.
>
> Dennis
>
>
> --
> ___
> 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] 1 keypress gives multiple letters ONLY in program written in Lazarus in raspbian jessie Pi 2

2016-04-10 Thread Dennis



Giuliano Colla wrote:

Il 09/04/2016 18:49, JuuS ha scritto:

Personally I had quite a fight with ibus and I finally removed it from
my system with no ill effects. It is mostly used AFAIK with asian
"alphabets".


There must be some problem with ibus/input methods in the Debian line, 
because it would appear that more or less all recent Debian based 
distro's (Ubuntu, Raspbian, ect.) show some weird keyboard behaviour, 
which wasn't present in the previous versions.


Red Hat line (Red Hat, Fedora, CentOs etc.) appears to be immune from 
this problem. I didn't find any complaint of this type on Internet, 
and when I have been forced to enable keyboard input methods to 
support Chinese, nothing strange happened (except when if you forget 
to switch back to English ;-) ...)


Maybe someone with a good knowledge of both worlds could find where 
the problem is?


Giuliano


I turned off Raspbian's Input Method and the problem is gone now.
thanks for everyone's tips.

Dennis

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


Re: [Lazarus] 1 keypress gives multiple letters ONLY in program written in Lazarus in raspbian jessie Pi 2

2016-04-09 Thread Giuliano Colla

Il 09/04/2016 18:49, JuuS ha scritto:

Personally I had quite a fight with ibus and I finally removed it from
my system with no ill effects. It is mostly used AFAIK with asian
"alphabets".


There must be some problem with ibus/input methods in the Debian line, 
because it would appear that more or less all recent Debian based 
distro's (Ubuntu, Raspbian, ect.) show some weird keyboard behaviour, 
which wasn't present in the previous versions.


Red Hat line (Red Hat, Fedora, CentOs etc.) appears to be immune from 
this problem. I didn't find any complaint of this type on Internet, and 
when I have been forced to enable keyboard input methods to support 
Chinese, nothing strange happened (except when if you forget to switch 
back to English ;-) ...)


Maybe someone with a good knowledge of both worlds could find where the 
problem is?


Giuliano


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


Re: [Lazarus] 1 keypress gives multiple letters ONLY in program written in Lazarus in raspbian jessie Pi 2

2016-04-09 Thread micsch
Am Saturday 09 April 2016 18:49:26 schrieb JuuS:


> Hi, yes its drastic but I wanted to know if ibus was the culprit.
>
> Personally I had quite a fight with ibus and I finally removed it from
> my system with no ill effects. It is mostly used AFAIK with asian
> "alphabets".

i  have the same Problem with PI 3 and mouseandkeyinput  for a touchscreen
numpad.

I´ll try the solution and report.
But the occurrence of problem is very random. 

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


Re: [Lazarus] 1 keypress gives multiple letters ONLY in program written in Lazarus in raspbian jessie Pi 2

2016-04-09 Thread JuuS


On 04/09/2016 06:03 PM, Giuliano Colla wrote:
> Il 09/04/2016 12:41, Dennis ha scritto:
>> But the SD Card was corrupted so I installed the latest raspbian OS
>> jessie on the same Pi 2 on a new SD Card.
>> I reinstalled everything (e.g. mysql etc) and my program and it runs
>> fine EXCEPT that pressing a key once will gives multiple letters.
>> BUT this problem only occurs with my program.   All other programs
>> e.g. web browser and file managers , text editor DO not have this problem.
> 
> The villain could be some "input method" active.
> Juus's suggestion is quite drastic, just kill the ibus service, which
> handles input methods.

Hi, yes its drastic but I wanted to know if ibus was the culprit.

Personally I had quite a fight with ibus and I finally removed it from
my system with no ill effects. It is mostly used AFAIK with asian
"alphabets".

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


Re: [Lazarus] 1 keypress gives multiple letters ONLY in program written in Lazarus in raspbian jessie Pi 2

2016-04-09 Thread Giuliano Colla

Il 09/04/2016 12:41, Dennis ha scritto:
But the SD Card was corrupted so I installed the latest raspbian OS 
jessie on the same Pi 2 on a new SD Card.
I reinstalled everything (e.g. mysql etc) and my program and it runs 
fine EXCEPT that pressing a key once will gives multiple letters.
BUT this problem only occurs with my program.   All other programs 
e.g. web browser and file managers , text editor DO not have this problem.


The villain could be some "input method" active.
Juus's suggestion is quite drastic, just kill the ibus service, which 
handles input methods.
Keyboard input methods configuration (setting to "none") could do the 
trick without killing all of the ibus services.


Giuliano

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


Re: [Lazarus] 1 keypress gives multiple letters ONLY in program written in Lazarus in raspbian jessie Pi 2

2016-04-09 Thread JuuS


On 04/09/2016 12:41 PM, Dennis wrote:
> In the past, the same program (written in lazarus ) running in the same
> hardware pi 2 under the older raspbian version has NO PROBLEM.
> 
> But the SD Card was corrupted so I installed the latest raspbian OS
> jessie on the same Pi 2 on a new SD Card.
> I reinstalled everything (e.g. mysql etc) and my program and it runs
> fine EXCEPT that pressing a key once will gives multiple letters.
> BUT this problem only occurs with my program.   

Remote possibility: do you have ibus installed and running? If so try
"ibus exit".

Julius

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


Re: [Lazarus] 1 keypress gives multiple letters ONLY in program written in Lazarus in raspbian jessie Pi 2

2016-04-09 Thread Michael Thompson
On 9 April 2016 at 18:41, Dennis  wrote:
> EXCEPT that pressing a key once will gives multiple letters.

We've had this before, under Ubuntu from memory.

Yup: http://bugs.freepascal.org/view.php?id=23140 (and related)

You may find some ideas in there.

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


[Lazarus] 1 keypress gives multiple letters ONLY in program written in Lazarus in raspbian jessie Pi 2

2016-04-09 Thread Dennis
In the past, the same program (written in lazarus ) running in the same 
hardware pi 2 under the older raspbian version has NO PROBLEM.


But the SD Card was corrupted so I installed the latest raspbian OS 
jessie on the same Pi 2 on a new SD Card.
I reinstalled everything (e.g. mysql etc) and my program and it runs 
fine EXCEPT that pressing a key once will gives multiple letters.
BUT this problem only occurs with my program.   All other programs e.g. 
web browser and file managers , text editor DO not have this problem.


I already set the Menu-> Preferences->Keyboard and Mouse->Keyboard-> 
Character Repeat->Repeat Delay to the maximum (1000 long)

but still does not help.

I cannot ask raspbian forum as they rarely write free pascal programs.

Can anyone think of what special things that lazarus GUI program uses 
(e.g. QT, gtk ) that might not work with the new raspbian jessie?


Note: I have tried installing FPC 3.0 and latest lazarus on the pi 2 
raspbian jessie and recompile the program but it has the same program.



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