Re: [g-a-devel]atk_hypertext_get_link_index



Bill,

Thanks for this.

I had lost sight of the fact that the offsets reported by AtkText interface are 
character offsets not byte offsets.

Padraig

> Subject: Re: [g-a-devel]atk_hypertext_get_link_index
> To: "Padraig O'Briain" <Padraig Obriain sun com>
> Cc: gnome-accessibility-devel gnome org
> Mime-Version: 1.0
> Content-Transfer-Encoding: 7bit
> 
> On Wed, 2003-02-12 at 08:15, Padraig O'Briain wrote:
> > I am looking at implementing the function atk_hypertext_get_link_index in 
the 
> > accessibility support for libgtkhtml2, the library used, inter alia, to 
display 
> > the help text for gnome-help.
> > 
> > I would like to make sure I understand correctly the paraemters to this 
> > function.
> > 
> > The second paraemter is called char_index. The description of the function 
> > implies that this value is not the same as the offset value used in AtkText 
> > functions for multibyte characters.
> > 
> > Is this correct?
> 
> I think this is a doc bug; we should certainly strive to be consistent
> in our definitions of "character offsets" within ATK.  It seems to me
> that the text 'offsets' in AtkHyperlink should be 'character' offsets
> rather than byte offsets.
> 
> I think the reason for the doc differences is that AtkHypertext doesn't
> have to be an AtkText implementor (perhaps confusingly, as far as
> nomenclature goes); that is, it should be possible for non-textual
> objects to implement AtkHypertext, in which case the 'offsets' will
> refer to something other then character offset.  The idea is that
> 'offset' will always be meaningful but the meaning may be context
> dependent, and that in tha case of AtkText implementors which also
> implement AtkHypertext, the offsets correspond to those used in the
> AtkText API.
> 
> -Bill
> 
> > 
> > In practice, how will the value used in a call to this function be obtained?
> > 
> > Padraig
> > 
> > _______________________________________________
> > Gnome-accessibility-devel mailing list
> > Gnome-accessibility-devel gnome org
> > http://mail.gnome.org/mailman/listinfo/gnome-accessibility-devel
> -- 
> Bill Haneman <bill haneman sun com>
> 




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]