Page 1 of 1

Strange Stuff with the Gambas editor

Posted: Wednesday 21st August 2019 1:02am
by Quincunxian
I have 2 issues in the code editor which have been plaguing me for a while.
I've seen nothing on the email list or here on the Forum so have to assume that it may well be a MAMCO.
(Me And My Computer Only).
The concern is that I had this on Ubuntu 18.n and have just recently moved to Mint 19.1 (Tessa) and the effects are the same.

1. The editor will 'freeze' and while I can move the cursor, I just can't edit any text at all.
This is random and I can go a long session without this happening but will occur 2-3 times in another session.
The simple fix is to save all and restart the editor and it's all working again.
It's random as far as I can see. I'm not doing anything special but it is possible that a sequence of events triggers this but I've not been able to determine what they are.

2. When I copy and paste code in a form that I'm working on; this can be any class or module code where I paste anything from a couple of lines to multiple subroutines.
I will get a ghost paste of what is normally the last function/sub block of code minus the declaration header at the end of the code page.

One or both of these events can happen in a tiny single form project or a quite large (5 Modules, 30+ Classes and Forms) and I do some long sessions with 4-8 hours not being uncommon.

I was wondering if anyone else had experienced these symptoms before and if they had a fix or at least knew what series of events triggers the behaviour.

Re: Strange Stuff with the Gambas editor

Posted: Wednesday 21st August 2019 11:49am
by Cedron
I have Mint 19 Mate installed on a different computer. I had some serious display problems until I installed the Qt5 packages.

On my Mint 17 Mate machine, occasionally, and very occasionally, clicking the mouse in the edit area is ineffective. The solution that seems to work is to click somewhere else outside of Gambas, then click again in the edit area.

Re: Strange Stuff with the Gambas editor

Posted: Wednesday 21st August 2019 11:43pm
by Quincunxian
Thanks Cedron,
The one other thing I noticed about the Gambas implementation on Mint is that TextBox backgrounds are no longer white by default but are form background(?) colour.
If you change them manually, you still get a ugly border of the original colour a few pixels wide.

I'll try the QT5 solution you tried and see if that helps.

For the editor freezing, I think I've tried cvlicking outside the editor but I'll grasp any straw offered and give that a go next time.

Thanks mate.
Quin.

Re: Strange Stuff with the Gambas editor

Posted: Tuesday 03rd September 2019 12:22am
by ercoupeflyer
I am having the same issue. Found if I use arrow key to move out of area it will allow the mouse to work again!

Re: Strange Stuff with the Gambas editor

Posted: Wednesday 11th September 2019 6:22am
by cage
I had a few problems but mostly with changing colors. I fixed most of those problems by using QT4/QT5 switcher component. I run Arch Linux and it mostly uses GTK3 but Gambas doesn't seem to like GTK3 very much. I don't know it it's a bug or that Gambas just doesn't like QT5 but for some reason it just doesn't work with QT4 anymore. I always get an error when trying to use QT4.

Re: Strange Stuff with the Gambas editor

Posted: Wednesday 11th September 2019 11:32pm
by Quincunxian
Hi cage,
I've never had much luck with the GTK component either
I found another strange behaviour yesterday when using the colour button control.
New projects just used the Gb.gui (QT/GTK Switcher ) which is the standard component for such I think.

Placed a colour button on the form I was working on and did some testing.
Clicking on a colour button at run time automatically opened a simple colour selection dialogue.
The one with the circle and the internal triangle for changing the required colour but once selected,
the displayed colour of the button did not change nor could I set it manually by setting the Color/Value
properties.

I change the component in project properties from GB.GUI to Gb.gui.qt.
Now clicking on the colour button opens a different more complex colour selection dialogue and also sets the colour of the button correctly. Also, now setting the colour of the button manually displays the correct colour.
Same outcome when swapping to the Gb.Qt4 component.

Unless someone smacks me up the back of the head and says "you're just doing it wrong".... which is quite possible, then I'll send something to the Gambas mailing list for investigation.

Re: Strange Stuff with the Gambas editor

Posted: Thursday 12th September 2019 3:03am
by Got2BeFree
Quincunxian wrote:
Wednesday 11th September 2019 11:32pm
Hi cage,
I've never had much luck with the GTK component either
I found another strange behaviour yesterday when using the colour button control.
New projects just used the Gb.gui (QT/GTK Switcher ) which is the standard component for such I think.

Placed a colour button on the form I was working on and did some testing.
Clicking on a colour button at run time automatically opened a simple colour selection dialogue.
The one with the circle and the internal triangle for changing the required colour but once selected, the displayed colour of the button did not change nor could I set it manually by setting the Color/Value
properties
.

I change the component in project properties from GB.GUI to Gb.gui.qt.
Now clicking on the colour button opens a different more complex colour selection dialogue and also sets the colour of the button correctly. Also, now setting the colour of the button manually displays the correct colour.
Same outcome when swapping to the Gb.Qt4 component.

Unless someone smacks me up the back of the head and says "you're just doing it wrong".... which is quite possible, then I'll send something to the Gambas mailing list for investigation.
Same issue with a TextEdit using QT5 component.

Re: Strange Stuff with the Gambas editor

Posted: Thursday 12th September 2019 3:35am
by cage
I change the component in project properties from GB.GUI to Gb.gui.qt.
Now clicking on the colour button opens a different more complex colour selection dialogue and also sets the colour of the button correctly. Also, now setting the colour of the button manually displays the correct colour.
Same outcome when swapping to the Gb.Qt4 component.

Unless someone smacks me up the back of the head and says "you're just doing it wrong".... which is quite possible, then I'll send something to the Gambas mailing list for investigation.
The only thing I will smack would be a pat on the back. The Gb.gui.qt solves all the problems with color at least on buttons and text boxes and text editor. Really nice find :P

Re: Strange Stuff with the Gambas editor

Posted: Thursday 12th September 2019 8:14am
by cage
Okay I tested it out with other controls, seems that only Buttons, TextArea, and TextEdit work. Otherwise colors will not change, so I think there is a problem with Gambas with setting colors.