FV_View::_getMouseContext函数,layout view mouse pos x , pos y
FV_View::_getPageForXY,具体算法参考:Abiword页面布局,系统默认的左边距是:1500,上边距是:375
减去页面内边距
fp_Page::mapXYToPosition函数中调用fp_VerticalContainer::mapXYToPosition(列)时,自动减去页面内边距。也可以理解成列的外边距,默认是1440。根据页面列的设置,循环所有的列用于确定坐标是否包含在该列中,然后调用fp_VerticalContainer::mapXYToPosition,该函数中要确定现在的y坐标能定位到那一行上(fp_Line)
Find first container that contains the point. First has its lower level below the desired Y
position. Note that X-positions are completely ignored here.
在fp_Line::mapXYToPosition函数中,循环该行包含的fp_Run对象,判断x坐标,最后定位x到Run对象内
原文:http://www.cnblogs.com/songtzu/p/3539784.html