Repository: nvaccess/nvda

Issue:
threshold_py3_staging: Say all isn't working in controls using DisplayModelEditableText
### Steps to reproduce:
1. Focus an edit box using DisplayModelEditableText (I was using Becky! Internet Mail as an example).
2. Press NVDA+down arrow to start say all.
### Actual behavior:
The first line is spoken, say all stops, error sound is played and the following is written in the log:
ERROR - speech.manager.SpeechManager._handleIndex (15:46:48.079):
Error running speech callback
Traceback (most recent call last):
  File "speech\manager.pyc", line 374, in _handleIndex
  File "speech\commands.pyc", line 260, in run
  File "sayAllHandler.pyc", line 145, in <lambda>
  File "sayAllHandler.pyc", line 176, in lineReached
  File "textInfos\offsets.pyc", line 615, in updateCaret
  File "displayModel.pyc", line 578, in _setCaretOffset
AttributeError: 'RectLTRB' object has no attribute 'x'
ERROR - speech.manager.SpeechManager._handleIndex (15:46:48.219):
Error running speech callback
Traceback (most recent call last):
  File "speech\manager.pyc", line 374, in _handleIndex
  File "speech\commands.pyc", line 260, in run
  File "sayAllHandler.pyc", line 145, in <lambda>
  File "sayAllHandler.pyc", line 176, in lineReached
  File "textInfos\offsets.pyc", line 615, in updateCaret
  File "displayModel.pyc", line 578, in _setCaretOffset
AttributeError: 'RectLTRB' object has no attribute 'x'
ERROR - speech.manager.SpeechManager._handleIndex (15:46:48.249):
Error running speech callback
Traceback (most recent call last):
  File "speech\manager.pyc", line 374, in _handleIndex
  File "speech\commands.pyc", line 260, in run
  File "sayAllHandler.pyc", line 145, in <lambda>
  File "sayAllHandler.pyc", line 176, in lineReached
  File "textInfos\offsets.pyc", line 615, in updateCaret
  File "displayModel.pyc", line 578, in _setCaretOffset
AttributeError: 'RectLTRB' object has no attribute 'x'


### Expected behavior:
Say all should work like it used to in Python 2 Version of NVDA.
### System configuration
#### NVDA installed/portable/running from source:
Portable
#### NVDA version:
NVDA version threshold_py3_staging-17927,9812e7b5
#### Windows version:
Windows 7 x64
#### Name and version of other software in use when reproducing the issue:
Becky! Internet Mail
#### Other information about your system:

### Other questions
#### Does the issue still occur after restarting your PC?
Yes
#### Have you tried any other versions of NVDA? If so, please report their behaviors.
Yes, Current Alpha snapshot works as expected and current threshold works also, so it propably isn't caused by speech refactor.


Discussion:
looks like I failed there. I will take this.


Resolving patch:
diff --git a/source/displayModel.py b/source/displayModel.py
--- a/source/displayModel.py
+++ b/source/displayModel.py
@@ -575,7 +575,7 @@ def _setCaretOffset(self,offset):
 		if offset>=len(rects):
 			raise RuntimeError("offset %d out of range")
 		rect = rects[offset]
-		x = rect.x
+		x = rect.left
 		y= rect.center.y
 		x,y=windowUtils.logicalToPhysicalPoint(self.obj.windowHandle,x,y)
 		oldX,oldY=winUser.getCursorPos()


Test patch: