K
Khronosx
Guest
Hi,
I used EM_SETMARGINS to set 10px margin on the right hand of the textbox.
It works fine when i am typing letters and exceeds the width of the textbox.
When the text is more than what textbox can hold, the text will shift left and the margin space is reserved.
However, once i have text and press "Home" key or left arrow to scroll back, the entire textbox is occupied (including the margin).
It looks like it happens if my textbox is set to be Left-to-Right and if i have margin on right side.
If I set the margin on the left side when the textbox is Left-to-Right, the margin is correct regardless where the current position is.
To make sure nothing is resetting the margin, in the rendering, i get the margin by EM_GETMARGINS and draw 2 lines for both left and right margin.
The line is at the right position regardless where the text is, but if i scroll the text back to the beginning, the right margin is ignored.
Is anything else experiencing this problem?
If so, is there any workaround?
Thanks!
Continue reading...
I used EM_SETMARGINS to set 10px margin on the right hand of the textbox.
It works fine when i am typing letters and exceeds the width of the textbox.
When the text is more than what textbox can hold, the text will shift left and the margin space is reserved.
However, once i have text and press "Home" key or left arrow to scroll back, the entire textbox is occupied (including the margin).
It looks like it happens if my textbox is set to be Left-to-Right and if i have margin on right side.
If I set the margin on the left side when the textbox is Left-to-Right, the margin is correct regardless where the current position is.
To make sure nothing is resetting the margin, in the rendering, i get the margin by EM_GETMARGINS and draw 2 lines for both left and right margin.
The line is at the right position regardless where the text is, but if i scroll the text back to the beginning, the right margin is ignored.
Is anything else experiencing this problem?
If so, is there any workaround?
Thanks!
Continue reading...