Re: Beginning of lines in text widget
From: Pascal Bouvier (pascal_at_prologianetNOSMAP.univ-mrs.fr)
Date: 11/11/03
- Next message: Bruce Hartweg: "Re: Beginning of lines in text widget"
- Previous message: Pascal Bouvier: "Re: Beginning of lines in text widget"
- In reply to: Pascal Bouvier: "Re: Beginning of lines in text widget"
- Next in thread: Bruce Hartweg: "Re: Beginning of lines in text widget"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Tue, 11 Nov 2003 20:46:18 +0100
Pascal Bouvier a écrit :
>
[about an Home key to jump to beginning of visual line instead of real line of text]
> set L [.t dlineinfo insert]
> .t mark set insert @[lindex $L 0],[expr [lindex $L 1]+[lindex $L 4]]
>
> should do the trick.
A "working" stuff:
proc u {W} {
set l [$W dlineinfo insert]
$W mark set insert @[lindex $l 0],[expr [lindex $l 1]+[lindex $l 4]];# @leftmarg,baseline
}
pack [text .t]
bind .t <Home> "u %W;break"
HTH,
-- Pascal
- Next message: Bruce Hartweg: "Re: Beginning of lines in text widget"
- Previous message: Pascal Bouvier: "Re: Beginning of lines in text widget"
- In reply to: Pascal Bouvier: "Re: Beginning of lines in text widget"
- Next in thread: Bruce Hartweg: "Re: Beginning of lines in text widget"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|