Author Topic: Scrolling  (Read 833 times)

johnno56

  • Guest
Scrolling
« on: September 20, 2014 »
I do not mean to be a pain in the neck, but that annoying "scrolling" effect, is back. It is most noticeable when working on a listing that is long. If I am working on the program, and I pause to think for a moment (which is rare indeed...), the listing scrolls down the screen then back to the line I was working on. Am I making any sense? Naalaa still runs well. It's more of an annoyance than anything else...

J

John

  • Sr. Member
  • ****
  • Posts: 362
    • View Profile
Re: Scrolling
« Reply #1 on: September 21, 2014 »
I do not mean to be a pain in the neck, but that annoying "scrolling" effect, is back. It is most noticeable when working on a listing that is long. If I am working on the program, and I pause to think for a moment (which is rare indeed...), the listing scrolls down the screen then back to the line I was working on. Am I making any sense? Naalaa still runs well. It's more of an annoyance than anything else...

J

No pain :) It's scanning for subroutines to add them to the list, and for some reason you see this happening. I have very little control over the IUP text edit widget, am hacking the underlying Windows RichEdit thingy (locking it in different ways while molesting it). Does it only jump around like this while you're taking a pause? What happens when you search for text or do a "find and replace" (kind of the same thing going on in the code then)? Do this also cause scrolling, because there should be none?

I'm not experiencing this issue myself, but I'll do some more tests. Does anyone else see it?


John

  • Sr. Member
  • ****
  • Posts: 362
    • View Profile
Re: Scrolling
« Reply #2 on: September 21, 2014 »
Can you try replacing NED.exe (C:\N6\) with the one in this zip? Confirm that the version number in the About dialog is 1.1.2. Also copy config.txt from the zip to the same folder as NED.exe. If it still keeps scrolling when you're inactive, try setting the @inactive value in config.txt to 0. This will disable the recording of subroutine names, which I guess is the better option until I manage to fix this.

You can also change colors and the font for the code windows using config.txt. Use normal RGB triplets separated by spaces:

Code: [Select]
@font       Courier New, 10
@reserved   0 0 200
@rem        128 128 128
@string     128 0 0
@other      0 0 0
@background 255 255 255
@inactive   5

John

  • Sr. Member
  • ****
  • Posts: 362
    • View Profile
Re: Scrolling
« Reply #3 on: September 21, 2014 »
Yes, a touch of professionalism :)

johnno56

  • Guest
Re: Scrolling
« Reply #4 on: September 21, 2014 »
Ned.exe 1.1.2 installed (about shows 1.1.2). Scrolling continued. Modified config.txt @inactive 5 to @inactive 0 and no more scrolling. Woo Hoo.. Many thanks, guys. YES!  I need more coffee...

J

johnno56

  • Guest
Re: Scrolling
« Reply #5 on: September 21, 2014 »
Here is my IDE ...

J

John

  • Sr. Member
  • ****
  • Posts: 362
    • View Profile
Re: Scrolling
« Reply #6 on: September 21, 2014 »
Ok, hope you can manage without the subroutine list until I get it working. Atleast you have nastier colors  now :)

Marcus

  • Administrator
  • Hero Member
  • *****
  • Posts: 541
    • View Profile
Re: Scrolling
« Reply #7 on: September 22, 2014 »
I've tried to copy your color scheme, Johnno, because it looks awesome :) Switched to the System font though.

Code: [Select]
@font       System, 10
@reserved   255 128 0
@rem        0 200 0
@string     255 255 0
@other      200 200 200
@background 0 0 0
@inactive   5

Never had any problems with unwanted scrolling.
« Last Edit: September 22, 2014 by Marcus »
.\\\opz

johnno56

  • Guest
Re: Scrolling
« Reply #8 on: September 22, 2014 »
Thanks Marcus. I am still of the opinion that, perhaps running N6 via Wine on my Linux box, contributes to the scrolling problem. But, at the moment, with "@inactive 0" in the config.txt file, all is quite stable. Here is my colour scheme.
Code: [Select]
@font       Courier New, 10
@reserved   255 128 0
@rem        0 128 0
@string     255 255 0
@other      192 192 192
@background 0 0 32
@inactive   0

I think 'your' System and 'my' System fonts are different. Mine looks a bit like Windows compact.tff  The program listing colours are as desired but the text is too "blocky" for my old eyes. How cool would "Old English" font look? I have "Klingon", but until I learn to read it, it's pretty useless... It's 8am and I haven't had my coffee yet... I'm outta here...

J

kcfb

  • Jr. Member
  • **
  • Posts: 80
    • View Profile
Re: Scrolling
« Reply #9 on: September 23, 2014 »
Hi...I usually stick with Windows...not used Linux for a year or more.....one reason is that I couldn't get NaaLaa working via Wine properly....thought I would try it again with Mint 17..wow...works straight out of the box....except the scrolling issue.....so I think it is a Wine problem I'm afraid...I'll try the fix tomorrow, but still so glad to see it working as Linux seems to run better/quicker on the older laptops I have....Kevin.

Marcus

  • Administrator
  • Hero Member
  • *****
  • Posts: 541
    • View Profile
Re: Scrolling
« Reply #10 on: September 23, 2014 »
I have to join the discussion. How exactly does wine work? I always thought of it as an emulator, but that's not quite true, right? Could it be that IUP uses GTK instead of win api when it's executed under wine? If so, the hack of the richedit control definitely won't work, since the underlying widget is something completely different.

What happens when you use undo? Does it count the syntax highlighting as an undo-step?

I've just installed Ubuntu on one of my computers, maybe I can have a look at it soon.

« Last Edit: September 23, 2014 by Marcus »
.\\\opz

kcfb

  • Jr. Member
  • **
  • Posts: 80
    • View Profile
Re: Scrolling
« Reply #11 on: September 23, 2014 »
I'll step away from the discussion I'm afraid Marcus - no knowledge of the workings of Wine - I just press the buttons and hope it works ;D....so maybe I was premature blaming Wine?

johnno56

  • Guest
Re: Scrolling
« Reply #12 on: September 23, 2014 »
Kcfb,

Sorry, but you are not the one who blamed Wine, it was me. You may continue to comment... ;)

Marcus,

Although I use Wine, I do not understand its inner workings. Perhaps your questions could be answered here: https://www.winehq.org/about/

J

Marcus

  • Administrator
  • Hero Member
  • *****
  • Posts: 541
    • View Profile
Re: Scrolling
« Reply #13 on: June 28, 2016 »
Old topic, I know.

But after moving to windows 10 i started seeing this GUI bug myself. It seems to appear if you, after making some changes to your code, scroll the edit window with its scrollbar or the mouse wheel so that the caret is no longer visible. When the editor starts it automatic scan for subroutines (for the dropdown list), the caret and scroll bounces up to the top of the document. I'll see what i can do about it.
.\\\opz

Marcus

  • Administrator
  • Hero Member
  • *****
  • Posts: 541
    • View Profile
Re: Scrolling
« Reply #14 on: June 28, 2016 »
Seems to be a bug in IUP (not in the naalaa extension). If the caret is not visible (due to scrolling) its position is always returned as (1, 1). So when the caret position is restored (after being modified while parsing all lines in the document), it's set to the top of the document.

As a temporary solution, as i really can't stand this bug, I'll change the editor so that it only parses for new subroutines when you save or load your document.


.\\\opz