Fossil repo up to date?

41 views
Skip to first unread message

will

unread,
Sep 28, 2011, 8:52:35 PM9/28/11
to tkhtml3
Hi,

I see that the home page doesn't mention the fossil repo at
tkhtml.tcl.tk/fossil. Is that the current official source?

In any case, I've been browsing the web with that version of hv3, and
encountered an error. Here is the fix. The problem is that the
get_selection method doesn't account for when the "html text offset"
command returns the empty string (it does, and the C source says it
can). Here is the output of fossil diff:

Index: hv/hv3.tcl
===================================================================
--- hv/hv3.tcl
+++ hv/hv3.tcl
@@ -786,11 +786,11 @@
$me motion $N $x $y
}

# get_selection OFFSET MAXCHARS
#
- # This command is invoked whenever the current selection is
selected
+ # This command is invoked whenever the current selection is
requested
# while it is owned by the html widget. The text of the
selected
# region is returned.
#
proc get_selection {me offset maxChars} {
upvar $me O
@@ -801,10 +801,13 @@
set n2 $O(myToNode)
set i2 $O(myToIdx)

set stridx_a [$O(myHv3) html text offset $O(myFromNode)
$O(myFromIdx)]
set stridx_b [$O(myHv3) html text offset $O(myToNode)
$O(myToIdx)]
+ if {$stridx_a eq "" || $stridx_b eq ""} {
+ return ""
+ }
if {$stridx_a > $stridx_b} {
foreach {stridx_a stridx_b} [list $stridx_b $stridx_a] {}
}

if {$O(myMode) eq "word"} {

Best,
Will

jemptymethod

unread,
Sep 29, 2011, 7:04:45 AM9/29/11
to tkhtml3
On Sep 28, 8:52 pm, will <phil.no...@gmail.com> wrote:
> Hi,
>
> I see that the home page doesn't mention the fossil repo at
> tkhtml.tcl.tk/fossil. Is that the current official source?

Yes it is the current official source but I don't the ability to
change the home page. The last change to the source was by Dan
Kennedy earlier this year. I also believe that D.Richard Hipp gave me
rights to the fossil repo earlier this year but I've been busy with
other things.

But timing might be good as I have somebody interested in my eReader
project based on hv3 and so plan to do more work in the upcoming
month. Will let the group know if I/we have rights to commit fixes to
the main fossil repo.

George
Reply all
Reply to author
Forward
0 new messages