English
Entrance

Error Scrolling...

 
- Page 1 -



RudiB.
Hello together,

have time again something...
at scroll over the control VSroll stay very often The Lines not "im Raster".
in a How I it otherwise squeeze out should.



Can the somehow fixen, the The Lines "im Raster bleiben" and not only The Half displayed becomes (supreme row !!)

23 kB
Hochgeladen:09/17/22
Downloadcounter61
Download
 
XProfan X4
Xprofan X4
Rudolf Beske / München

Hardware: NB Intel I9 - 16GByte RAM
09/17/22  
 



« this Posting watts as Solution marked. »


Georg
Teles
good tommorrow,

be since one year out from the Programming. have order Style nothing suitable found, only Workarounds which The "Justierung the Zeile" as an afterthought distinguished ... as Denkanstoß here small example, umständlich, is vllt useful: (with Edit and Control first hineinklicken, then which VScroll activate because Focus/Child, can sodann with ProcAddr correct go)
Cls
var Text$ = GenTxt()
Declare pre_pos&

Proc GenTxt

    Declare tx$
    tx$ = ""

    WhileLoop 0,200

        tx$ = tx$+"Text_"+Str $(&loop)+"\n"

    EndWhile

    tx$ = tx$+"ENDE"
    Return tx$

ENDPROC

locate 0,0
print "RichEdit"
locate 0,27
print "Edit (Control)"
locate 0,54
print "VScroll"
var red& = Create("richedit", %hWnd, Text$, 5, 25, 200, 200)
var red2& = Control("Edit", "", $50200044, 205, 25, 200, 200, %hWnd, 0, %hInstance)
var vsc& = Create("VScroll",%hWnd,"",422,25,20,200)
'ACHTUNG size the VScroll mind ! on the best to Lines less Visible Lines
'SetScrollRange vsc&,0,190
'$00BA 'em_GetLineCount - Visible Lines (here 11)
SetScrollRange vsc&,0,SendMessage(red&,$00BA,0,0)-11
SetText red&,Text$
SetText red2&,Text$

While 1=1

    Waitinput
    'if Focus on VScroll

    If GetFocus(vsc&)

        SendMessage(red&,$00B6,0,GetScrollPos(vsc&)-pre_pos&)
        SendMessage(red2&,$00B6,0,GetScrollPos(vsc&)-pre_pos&)
        pre_pos& = GetScrollPos(vsc&)
        locate 3,57
        print "GoTO Line "+Str $(pre_pos&)+Space$(3)

    EndIf

    'if Focus on RichEdit

    If GetFocus(red&)

        SendMessage(red&,$00B6,0,GetScrollPos(vsc&)-pre_pos&)
        SendMessage(red2&,$00B6,0,SendMessage(red&,$00CE,0,0)-pre_pos&)
        pre_pos& = SendMessage(red&,$00CE,0,0)
        SetScrollPos vsc&, pre_pos&
        locate 3,57
        print "GoTO Line "+Str $(pre_pos&)+Space$(3)

    EndIf

    'if Focus on ControlEDIT

    If GetFocus(red2&)

        SendMessage(red2&,$00B6,0,GetScrollPos(vsc&)-pre_pos&)
        SendMessage(red&,$00B6,0,SendMessage(red2&,$00CE,0,0)-pre_pos&)
        pre_pos& = SendMessage(red2&,$00CE,0,0)
        SetScrollPos vsc&, pre_pos&
        locate 3,57
        print "GoTO Line "+Str $(pre_pos&)+Space$(3)

    EndIf

endwhile


Regards
 
XProfan X2
TC-Programming [...] 
XProfan 8.0 - 10.0 - X2 - X3 - X4

10/01/22  
 




RudiB.
another small Nachtrag...
this is only one Richedit so, in the MultiEdit functions the scroll really Zeilenweise.
I need the but in Richedit so...
 
XProfan X4
Xprofan X4
Rudolf Beske / München

Hardware: NB Intel I9 - 16GByte RAM
09/18/22  
 




Georg
Teles
good tommorrow,

be since one year out from the Programming. have order Style nothing suitable found, only Workarounds which The "Justierung the Zeile" as an afterthought distinguished ... as Denkanstoß here small example, umständlich, is vllt useful: (with Edit and Control first hineinklicken, then which VScroll activate because Focus/Child, can sodann with ProcAddr correct go)
Cls
var Text$ = GenTxt()
Declare pre_pos&

Proc GenTxt

    Declare tx$
    tx$ = ""

    WhileLoop 0,200

        tx$ = tx$+"Text_"+Str $(&loop)+"\n"

    EndWhile

    tx$ = tx$+"ENDE"
    Return tx$

ENDPROC

locate 0,0
print "RichEdit"
locate 0,27
print "Edit (Control)"
locate 0,54
print "VScroll"
var red& = Create("richedit", %hWnd, Text$, 5, 25, 200, 200)
var red2& = Control("Edit", "", $50200044, 205, 25, 200, 200, %hWnd, 0, %hInstance)
var vsc& = Create("VScroll",%hWnd,"",422,25,20,200)
'ACHTUNG size the VScroll mind ! on the best to Lines less Visible Lines
'SetScrollRange vsc&,0,190
'$00BA 'em_GetLineCount - Visible Lines (here 11)
SetScrollRange vsc&,0,SendMessage(red&,$00BA,0,0)-11
SetText red&,Text$
SetText red2&,Text$

While 1=1

    Waitinput
    'if Focus on VScroll

    If GetFocus(vsc&)

        SendMessage(red&,$00B6,0,GetScrollPos(vsc&)-pre_pos&)
        SendMessage(red2&,$00B6,0,GetScrollPos(vsc&)-pre_pos&)
        pre_pos& = GetScrollPos(vsc&)
        locate 3,57
        print "GoTO Line "+Str $(pre_pos&)+Space$(3)

    EndIf

    'if Focus on RichEdit

    If GetFocus(red&)

        SendMessage(red&,$00B6,0,GetScrollPos(vsc&)-pre_pos&)
        SendMessage(red2&,$00B6,0,SendMessage(red&,$00CE,0,0)-pre_pos&)
        pre_pos& = SendMessage(red&,$00CE,0,0)
        SetScrollPos vsc&, pre_pos&
        locate 3,57
        print "GoTO Line "+Str $(pre_pos&)+Space$(3)

    EndIf

    'if Focus on ControlEDIT

    If GetFocus(red2&)

        SendMessage(red2&,$00B6,0,GetScrollPos(vsc&)-pre_pos&)
        SendMessage(red&,$00B6,0,SendMessage(red2&,$00CE,0,0)-pre_pos&)
        pre_pos& = SendMessage(red2&,$00CE,0,0)
        SetScrollPos vsc&, pre_pos&
        locate 3,57
        print "GoTO Line "+Str $(pre_pos&)+Space$(3)

    EndIf

endwhile


Regards
 
XProfan X2
TC-Programming [...] 
XProfan 8.0 - 10.0 - X2 - X3 - X4

10/01/22  
 




RudiB.
Hello Georg,

... danke, this is, faith I The Solution. Do I in silence try.
but on the first look very the right, I sought have.
I Try the today evening times for my drop from and give then Feedback.

Greeting Rudi
 
XProfan X4
Xprofan X4
Rudolf Beske / München

Hardware: NB Intel I9 - 16GByte RAM
10/01/22  
 




RudiB.
...already ausprobiert.... TREFFER....

thanks Georg, the wars...

Greeting from munich
Rudi
 
XProfan X4
Xprofan X4
Rudolf Beske / München

Hardware: NB Intel I9 - 16GByte RAM
10/01/22  
 




Georg
Teles
good evening, well wonderful

Regards
 
XProfan X2
TC-Programming [...] 
XProfan 8.0 - 10.0 - X2 - X3 - X4

10/01/22  
 



Answer


Topictitle, max. 100 characters.
 

Systemprofile:

no Systemprofil laid out. [anlegen]

XProfan:

 Posting  Font  Smilies  ▼ 

Please register circa a Posting To verfassen.
 

Topic-Options

2.552 Views

Themeninformationen

this Topic has 2 subscriber:

RudiB. (4x)
Georg Teles (2x)


Admins  |  AGB  |  Applications  |  Authors  |  Chat  |  Privacy Policy  |  Download  |  Entrance  |  Help  |  Merchantportal  |  Imprint  |  Mart  |  Interfaces  |  SDK  |  Services  |  Games  |  Search  |  Support

One proposition all XProfan, The there's!


My XProfan
Private Messages
Own Storage Forum
Topics-Remember-List
Own Posts
Own Topics
Clipboard
Log off
 Deutsch English Français Español Italia
Translations

Privacy Policy


we use Cookies only as Session-Cookies because of the technical necessity and with us there no Cookies of Drittanbietern.

If you here on our Website click or navigate, stimmst You ours registration of Information in our Cookies on XProfan.Net To.

further Information To our Cookies and moreover, How You The control above keep, find You in ours nachfolgenden Datenschutzerklärung.


all rightDatenschutzerklärung
i want none Cookie