Hi Tom, Without a reproducible testcase it is hard to see what is happening. Are you using Text or TextFlow ? For some reason the Text.getImpl_caretShape() seems to think the caret is in the 8th line, which seems to indicate there is some line wrapping width set when it should not (Jim just fixed a bug in that code last week).
Regards, Felipe > On Nov 23, 2014, at 11:04 AM, Tom Schindl <[email protected]> wrote: > > Hi, > > I was debugging a problem in my StyledText-Source editor today and found > one of my layout problems is that ListCells (the inner representation of > the editor lines is simply ListView) sometime get really strange heights > assigned. > > To display a caret in the UI I'm creating a caret-Shape using > Text.getImpl_caretShape but this is causeing my layout problems because > under certain conditions the returned cursor is completely wrong. > > Look for example at the following example. The first line is the bounds > of the Text-Element with the content (privata) and the 2nd is the Path > created by Text.getImpl_caretShape > >> BoundingBox [minX:0.0, minY:0.0, minZ:0.0, width:81.01318359375, >> height:15.0, depth:0.0, maxX:81.01318359375, maxY:15.0, maxZ:0.0] >> privata ===> [MoveTo[x=9.00146484375, y=120.0], LineTo[x=9.00146484375, >> y=135.0]] > > the correct path is [MoveTo[x=9.00146484375, y=0.0], > LineTo[x=9.00146484375, y=15.0]] > > > I've been able to work around this problem for the time being. Anyone an > idea what is causing this completely invalid caretShape? > > Tom > > -- > Thomas Schindl, CTO > BestSolution.at EDV Systemhaus GmbH > Eduard-Bodem-Gasse 5-7, A-6020 Innsbruck > http://www.bestsolution.at/ > Reg. Nr. FN 222302s am Firmenbuchgericht Innsbruck
