Posted 17 years ago by Marianne
Version: 4.0.0253
Avatar
In my application, when creating a new editor control (all using the same syntaxlanguage) and reloading the user's preferences, if the user has wrapping turned on with no width specified then it always comes up 4 characters wide. If a width is specified then everything works normally. The only way to force the control to update is to actually resize the control. Calling Refresh() or RefreshOutlining() doesn't make any difference. This is not immediately reproduceble in the sample app.

I believe what is happening is that in whatever unusual sequence I'm initializing things, somewhere you have code that says if the wrap width is < 4 then width = 4 (in other words not accounting for -1). When resizing the control the correct logic takes over and fills the screen.

I'll look to repro this in the sample app (which may not be possible) but can you double-check that there are no circumstances under which you're forcing the width? Thanks.

------------------------------- Marianne

Comments (3)

Posted 17 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
Hi Marianne,

I'm wondering if perhaps the control's default size is being used in this case since I think at runtime you can actually go down to 1 character width. Still if you get a repro, that would be helpful.

In the meantime, does calling this on the control help?
editor.Invalidate(ActiproSoftware.WinUICore.InvalidationLevels.ElementAndChildren, ActiproSoftware.WinUICore.InvalidationTypes.All);


Actipro Software Support

Posted 17 years ago by Marianne
Avatar
Odd... I call invalidate() after it loads and it still doesn't update itself until wraptype is changed or the control is resized.

------------------------------- Marianne

Posted 17 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
Hi Marianne,

Continue to try and dupe it in a small sample app and once you get it, please email it over so we can debug what is happening. In the meantime, I suppose you'll have to resize the control programmatically really quick right after setting that property. Thanks!


Actipro Software Support

The latest build of this product (v24.1.0) was released 2 months ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.