Closed Gillibald closed 2 years ago
There are a few more, if editing text is an ongoing work, it can be addressed after merge.
(from ControlCatalog):
<TextBox Width="200" Text="RightToLeft text" FlowDirection="RightToLeft" />
has bouncy selection:אבג 1
not selected:<TextBox Width="200" Text="אבג 1" TextAlignment="Left" />
The cursor goes backwards by typing a space:<TextBox Width="200" FlowDirection="RightToLeft" />
Type א
and then a
changes the baseline:Originally posted by @danielmayost in https://github.com/AvaloniaUI/Avalonia/issues/4893#issuecomment-1026208611
אAאAאA
selected all, there is a break between the glyphs:FlowDirection="RightToLeft"
, should be reversed like notepad (left arrow advances in logical order).yes, should be like windows notepad etc. in most programs, this is how it works.
https://user-images.githubusercontent.com/3163374/152086985-32b8c842-25e7-4eff-970b-6321427f44e0.mp4
https://user-images.githubusercontent.com/1270275/152163399-cc8c4abe-fe79-446c-b7a1-cc3a3868ec74.mp4
it looks like two bugs at the 5. and 11. sec. it should not change the selection
Note: I tested them against the branch in https://github.com/AvaloniaUI/Avalonia/pull/7509
ABC אבג
) against #7509:
Before -
After -
When setting RTL flow direction causing controls to stretch indefinitely. Before -
After -
Must be something special about Menu/Flyout will try to reproduce it
When setting RTL flow direction causing controls to stretch indefinitely. Before - After -
Must be something special about Menu/Flyout will try to reproduce it
It seems to happen to almost everything. I might be using it wrong? Tried setting FlowDirection
to all TextBlock
s using a Style
Before:
After:
Setting TextAlignment.Right and FlowDirection.LeftToRight most likely has the same issue
@Gillibald sharing here a few exceptions from users, I haven't personally reproduced all of them, but they do not happen on previous version of my app (only change is Avalonia from 0.10.12 -> master).
System.ArgumentOutOfRangeException: Specified argument was out of the range of valid values. (Parameter 'length')
Avalonia.Media.TextFormatting
FormattedTextSource.CreateTextStyleRun (ReadOnlySlice`1 text, TextRunProperties defaultProperties, IReadOnlyList`1 textModifier)
Avalonia.Media.TextFormatting
FormattedTextSource.GetTextRun (Int32 textSourceIndex)
Avalonia.Media.TextFormatting
TextFormatterImpl.FetchTextRuns (ITextSource textSource, Int32 firstTextSourceIndex, TextEndOfLine& endOfLine, TextRange& textRange)
Avalonia.Media.TextFormatting
TextFormatterImpl.FormatLine (ITextSource textSource, Int32 firstTextSourceIndex, Double paragraphWidth, TextParagraphProperties paragraphProperties, TextLineBreak previousLineBreak)
Avalonia.Media.TextFormatting
TextLayout.CreateTextLines ()
Avalonia.Controls.Presenters
TextPresenter.CreateTextLayoutInternal (Size constraint, String text, Typeface typeface, IReadOnlyList`1 textStyleOverrides)
Avalonia.Controls.Presenters
TextPresenter.CreateTextLayout ()
Avalonia.Controls.Presenters
TextPresenter.get_TextLayout ()
Avalonia.Controls.Presenters
TextPresenter.MoveCaretToTextPosition (Int32 textPosition, Boolean trailingEdge)
Avalonia
DirectProperty`2.InvokeSetter (IAvaloniaObject instance, BindingValue`1 value)
Avalonia
AvaloniaObject.SetDirectValueUnchecked[T] (DirectPropertyBase`1 property, BindingValue`1 value)
Avalonia.AvaloniaObject
DirectBindingSubscription`1.OnNext (BindingValue`1 value)
Avalonia.Reactive
TypedBindingAdapter`1.OnNext (BindingValue`1 value)
Avalonia.Reactive
BindingValueAdapter`1.OnNext (T value)
Avalonia
AvaloniaObject.RaisePropertyChanged[T] (AvaloniaPropertyChangedEventArgs`1 change)
Avalonia.Controls
TextBox.set_CaretIndex (Int32 value)
Avalonia.Controls
TextBox.DeleteSelection (Boolean raiseTextChanged)
Avalonia.Controls
TextBox.OnKeyDown (KeyEventArgs e)
System.Reactive.Subjects
Subject`1.OnNext (T value) /_/Rx.NET/Source/src/System.Reactive/Subjects/Subject.cs:145
Avalonia.Interactivity
EventRoute.RaiseEventImpl (RoutedEventArgs e)
Avalonia.Interactivity
EventRoute.RaiseEvent (IInteractive source, RoutedEventArgs e)
Avalonia.Interactivity
Interactive.RaiseEvent (RoutedEventArgs e)
Avalonia.Input
KeyboardDevice.ProcessRawEvent (RawInputEventArgs e)
Avalonia.Input
InputManager.ProcessInput (RawInputEventArgs e)
Avalonia.Win32
WindowImpl.AppWndProc (IntPtr hWnd, UInt32 msg, IntPtr wParam, IntPtr lParam)
Avalonia.Win32
WindowImpl.WndProc (IntPtr hWnd, UInt32 msg, IntPtr wParam, IntPtr lParam)
Avalonia.Win32.Interop
UnmanagedMethods.DispatchMessage (MSG& lpmsg)
Avalonia.Win32
Win32Platform.RunLoop (CancellationToken cancellationToken)
Avalonia.Threading
Dispatcher.MainLoop (CancellationToken cancellationToken)
Avalonia.Controls.ApplicationLifetimes
ClassicDesktopStyleApplicationLifetime.Start (String[] args)
System.ArgumentOutOfRangeException: Specified argument was out of the range of valid values. (Parameter 'length')
Avalonia.Utilities
ReadOnlySlice`1.Take (Int32 length)
Avalonia.Media.TextFormatting
FormattedTextSource.CreateTextStyleRun (ReadOnlySlice`1 text, TextRunProperties defaultProperties, IReadOnlyList`1 textModifier)
Avalonia.Media.TextFormatting
TextFormatterImpl.FetchTextRuns (ITextSource textSource, Int32 firstTextSourceIndex, TextEndOfLine& endOfLine, TextRange& textRange)
Avalonia.Media.TextFormatting
TextLayout.CreateTextLines ()
Avalonia.Media.TextFormatting.TextLayout
Avalonia.Media.TextFormatting.TextLayout..ctor(String text, Typeface typeface, Double fontSize, IBrush foreground, TextAlignment textAlignment, TextWrapping textWrapping, TextTrimming textTrimming, TextDecorationCollection textDecorations, FlowDirection flowDirection, Double maxWidth, Double maxHeight, Double lineHeight, Int32 maxLines, IReadOnlyList`1 textStyleOverrides)
Avalonia.Controls.Presenters
TextPresenter.CreateTextLayoutInternal (Size constraint, String text, Typeface typeface, IReadOnlyList`1 textStyleOverrides)
Avalonia.Controls.Presenters
TextPresenter.CreateTextLayout ()
Avalonia.Controls.Presenters
TextPresenter.get_TextLayout ()
Avalonia.Controls.Presenters
TextPresenter.MoveCaretToTextPosition (Int32 textPosition, Boolean trailingEdge)
Avalonia.Controls.Presenters
TextPresenter.set_CaretIndex (Int32 value)
Avalonia.Controls.Presenters.TextPresenter.<>c
<.cctor>b__24_1 (TextPresenter o, Int32 v)
Avalonia
DirectProperty`2.InvokeSetter (IAvaloniaObject instance, BindingValue`1 value)
Avalonia
AvaloniaObject.SetDirectValueUnchecked[T] (DirectPropertyBase`1 property, BindingValue`1 value)
Avalonia.AvaloniaObject
DirectBindingSubscription`1.OnNext (BindingValue`1 value)
Avalonia.Reactive
SingleSubscriberObservableBase`1.PublishNext (T value)
Avalonia.Reactive
TypedBindingAdapter`1.OnNext (BindingValue`1 value)
Avalonia.Reactive
BindingValueAdapter`1.OnNext (T value)
Avalonia.Data
TemplateBinding.TemplatedParentPropertyChanged (Object sender, AvaloniaPropertyChangedEventArgs e)
Avalonia
AvaloniaObject.RaisePropertyChanged[T] (AvaloniaPropertyChangedEventArgs`1 change)
Avalonia
AvaloniaObject.SetAndRaise[T] (AvaloniaProperty`1 property, T& field, T value)
Avalonia.Controls
TextBox.set_CaretIndex (Int32 value)
Avalonia.Controls
TextBox.DeleteSelection (Boolean raiseTextChanged)
Avalonia.Controls
TextBox.OnKeyDown (KeyEventArgs e)
Avalonia.Input.InputElement.<>c
<.cctor>b__32_2 (InputElement x, KeyEventArgs e)
System.Reactive
ObserverBase`1.OnNext (T value) /_/Rx.NET/Source/src/System.Reactive/ObserverBase.cs:32
Avalonia.Interactivity
EventRoute.RaiseEventImpl (RoutedEventArgs e)
Avalonia.Interactivity
Interactive.RaiseEvent (RoutedEventArgs e)
Avalonia.Input
KeyboardDevice.ProcessRawEvent (RawInputEventArgs e)
Avalonia.Controls
TopLevel.HandleInput (RawInputEventArgs e)
Avalonia.Win32
WindowImpl.AppWndProc (IntPtr hWnd, UInt32 msg, IntPtr wParam, IntPtr lParam)
Avalonia.Win32
WindowImpl.WndProc (IntPtr hWnd, UInt32 msg, IntPtr wParam, IntPtr lParam)
Avalonia.Win32.Interop
UnmanagedMethods.DispatchMessage (MSG& lpmsg)
Avalonia.Win32
Win32Platform.RunLoop (CancellationToken cancellationToken)
Avalonia.Threading
Dispatcher.MainLoop (CancellationToken cancellationToken)
Avalonia.Controls.ApplicationLifetimes
ClassicDesktopStyleApplicationLifetime.Start (String[] args)
System.NullReferenceException: Object reference not set to an instance of an object.
Avalonia.Media.TextFormatting
TextFormatterImpl.MeasureLength (IReadOnlyList`1 textRuns, TextRange textRange, Double paragraphWidth)
Avalonia.Media.TextFormatting
TextFormatterImpl.PerformTextWrapping (List`1 textRuns, TextRange textRange, Double paragraphWidth, TextParagraphProperties paragraphProperties, FlowDirection flowDirection, TextLineBreak currentLineBreak)
Avalonia.Media.TextFormatting
TextLayout.CreateTextLines ()
Avalonia.Controls
TextBlock.CreateTextLayout (Size constraint, String text)
Avalonia.Controls
TextBlock.MeasureOverride (Size availableSize)
Avalonia.Layout
Layoutable.MeasureCore (Size availableSize)
Avalonia.Layout
Layoutable.Measure (Size availableSize)
Avalonia.Layout
LayoutManager.Measure (ILayoutable control)
Avalonia.Layout
LayoutManager.ExecuteLayoutPass ()
Avalonia.Threading
JobRunner.RunJobs (Nullable`1 priority)
Avalonia.Win32
Win32Platform.WndProc (IntPtr hWnd, UInt32 msg, IntPtr wParam, IntPtr lParam)
Avalonia.Win32.Interop
UnmanagedMethods.DispatchMessage (MSG& lpmsg)
Avalonia.Win32
Win32Platform.RunLoop (CancellationToken cancellationToken)
Avalonia.Threading
Dispatcher.MainLoop (CancellationToken cancellationToken)
Avalonia.Controls.ApplicationLifetimes
ClassicDesktopStyleApplicationLifetime.Start (String[] args)
System.ArgumentOutOfRangeException: Index and length must refer to a location within the string. (Parameter 'length')
System
String.Substring (Int32 startIndex, Int32 length)
Avalonia.Controls
TextBox.HandleTextInput (String input)
Avalonia.Controls
TextBox.OnTextInput (TextInputEventArgs e)
Avalonia.Input.InputElement.<>c
<.cctor>b__32_4 (InputElement x, TextInputEventArgs e)
System.Reactive.Subjects
Subject`1.OnNext (T value) /_/Rx.NET/Source/src/System.Reactive/Subjects/Subject.cs:145
Avalonia.Interactivity
EventRoute.RaiseEventImpl (RoutedEventArgs e)
Avalonia.Interactivity
EventRoute.RaiseEvent (IInteractive source, RoutedEventArgs e)
Avalonia.Interactivity
Interactive.RaiseEvent (RoutedEventArgs e)
Avalonia.Input
KeyboardDevice.ProcessRawEvent (RawInputEventArgs e)
Avalonia.Input
InputManager.ProcessInput (RawInputEventArgs e)
Avalonia.Win32
WindowImpl.AppWndProc (IntPtr hWnd, UInt32 msg, IntPtr wParam, IntPtr lParam)
Avalonia.Win32
WindowImpl.WndProc (IntPtr hWnd, UInt32 msg, IntPtr wParam, IntPtr lParam)
Avalonia.Win32.Interop
UnmanagedMethods.DispatchMessage (MSG& lpmsg)
Avalonia.Win32
Win32Platform.RunLoop (CancellationToken cancellationToken)
Avalonia.Threading
Dispatcher.MainLoop (CancellationToken cancellationToken)
Avalonia.Controls.ApplicationLifetimes
ClassicDesktopStyleApplicationLifetime.Start (String[] args)
System.ArgumentNullException: Value cannot be null. (Parameter 'name'
Avalonia.Media.FontFamily
Avalonia.Media.FontFamily..ctor(Uri baseUri, String name)
Avalonia.Media.FontFamily
Avalonia.Media.FontFamily..ctor(String name)
Avalonia.Media.Typeface
Avalonia.Media.Typeface..ctor(String fontFamilyName, FontStyle style, FontWeight weight)
Avalonia.Skia
FontManagerImpl.TryMatchCharacter (Int32 codepoint, FontStyle fontStyle, FontWeight fontWeight, FontFamily fontFamily, CultureInfo culture, Typeface& fontKey)
Avalonia.Media
FontManager.TryMatchCharacter (Int32 codepoint, FontStyle fontStyle, FontWeight fontWeight, FontFamily fontFamily, CultureInfo culture, Typeface& typeface)
Avalonia.Media.TextFormatting
TextCharacters.CreateShapeableRun (ReadOnlySlice`1 text, TextRunProperties defaultProperties, SByte biDiLevel, TextRunProperties& previousProperties)
Avalonia.Media.TextFormatting
TextFormatterImpl.CoalesceLevels (IReadOnlyList`1 textCharacters, ReadOnlySlice`1 levels) +MoveNext()
Avalonia.Media.TextFormatting
TextFormatterImpl.ShapeTextRuns (List`1 textRuns, FlowDirection flowDirection, FlowDirection& resolvedFlowDirection)
Avalonia.Media.TextFormatting
TextLayout.CreateTextLines ()
Avalonia.Controls
TextBlock.CreateTextLayout (Size constraint, String text)
Avalonia.Controls
TextBlock.MeasureOverride (Size availableSize)
Avalonia.Layout
Layoutable.MeasureCore (Size availableSize)
Avalonia.Layout
Layoutable.Measure (Size availableSize)
Avalonia.Controls
DockPanel.MeasureOverride (Size constraint)
Avalonia.Layout
Layoutable.MeasureCore (Size availableSize)
Avalonia.Layout
Layoutable.Measure (Size availableSize)
Avalonia.Layout
LayoutHelper.MeasureChild (ILayoutable control, Size availableSize, Thickness padding)
Avalonia.Controls.Presenters
ContentPresenter.MeasureOverride (Size availableSize)
Avalonia.Layout
Layoutable.MeasureCore (Size availableSize)
Avalonia.Layout
Layoutable.Measure (Size availableSize)
Avalonia.Layout
Layoutable.MeasureOverride (Size availableSize)
Avalonia.Layout
Layoutable.MeasureCore (Size availableSize)
Avalonia.Layout
Layoutable.Measure (Size availableSize)
Avalonia.Layout
Layoutable.MeasureOverride (Size availableSize)
Avalonia.Layout
Layoutable.MeasureCore (Size availableSize)
Avalonia.Layout
Layoutable.Measure (Size availableSize)
Avalonia.Layout
LayoutHelper.MeasureChild (ILayoutable control, Size availableSize, Thickness padding)
Avalonia.Controls.Presenters
ContentPresenter.MeasureOverride (Size availableSize)
Avalonia.Layout
Layoutable.MeasureCore (Size availableSize)
Avalonia.Layout
Layoutable.Measure (Size availableSize)
Avalonia.Layout
Layoutable.MeasureOverride (Size availableSize)
Avalonia.Layout
Layoutable.MeasureCore (Size availableSize)
Avalonia.Layout
Layoutable.Measure (Size availableSize)
Avalonia.Layout
LayoutHelper.MeasureChild (ILayoutable control, Size availableSize, Thickness padding)
Avalonia.Controls
Border.MeasureOverride (Size availableSize)
Avalonia.Layout
Layoutable.MeasureCore (Size availableSize)
Avalonia.Layout
Layoutable.Measure (Size availableSize)
Avalonia.Layout
Layoutable.MeasureOverride (Size availableSize)
Avalonia.Layout
Layoutable.MeasureCore (Size availableSize)
Avalonia.Layout
Layoutable.Measure (Size availableSize)
Avalonia.Layout
LayoutHelper.MeasureChild (ILayoutable control, Size availableSize, Thickness padding)
Avalonia.Controls.Presenters
ContentPresenter.MeasureOverride (Size availableSize)
Avalonia.Layout
Layoutable.MeasureCore (Size availableSize)
Avalonia.Layout
Layoutable.Measure (Size availableSize)
Avalonia.Controls
StackPanel.MeasureOverride (Size availableSize)
Avalonia.Layout
Layoutable.MeasureCore (Size availableSize)
Avalonia.Layout
Layoutable.Measure (Size availableSize)
Avalonia.Controls.Presenters
ItemVirtualizer.MeasureOverride (Size availableSize)
Avalonia.Controls.Presenters
ItemsPresenter.MeasureOverride (Size availableSize)
Avalonia.Layout
Layoutable.MeasureCore (Size availableSize)
Avalonia.Layout
Layoutable.Measure (Size availableSize)
Avalonia.Controls
DockPanel.MeasureOverride (Size constraint)
Avalonia.Layout
Layoutable.MeasureCore (Size availableSize)
Avalonia.Layout
Layoutable.Measure (Size availableSize)
Avalonia.Layout
LayoutManager.Measure (ILayoutable control)
Avalonia.Layout
LayoutManager.Measure (ILayoutable control)
Avalonia.Layout
LayoutManager.Measure (ILayoutable control)
Avalonia.Layout
LayoutManager.Measure (ILayoutable control)
Avalonia.Layout
LayoutManager.Measure (ILayoutable control)
Avalonia.Layout
LayoutManager.ExecuteMeasurePass ()
Avalonia.Layout
LayoutManager.InnerLayoutPass ()
Avalonia.Layout
LayoutManager.ExecuteLayoutPass ()
Avalonia.Threading
JobRunner.RunJobs (Nullable`1 priority)
Avalonia.Win32
Win32Platform.WndProc (IntPtr hWnd, UInt32 msg, IntPtr wParam, IntPtr lParam)
Avalonia.Win32.Interop
UnmanagedMethods.DispatchMessage (MSG& lpmsg)
Avalonia.Win32
Win32Platform.RunLoop (CancellationToken cancellationToken)
Avalonia.Threading
Dispatcher.MainLoop (CancellationToken cancellationToken)
Avalonia.Controls.ApplicationLifetimes
ClassicDesktopStyleApplicationLifetime.Start (String[] args)
@adirh3 Is there dynamic text displayed by TextBlocks in your app or is it just static? Ideally those users could give me more info about the actual text they were typing or what they were doing at the moment of the crash.
@adirh3 Is there dynamic text displayed by TextBlocks in your app or is it just static? Ideally those users could give me more info about the actual text they were typing or what they were doing at the moment of the crash.
I believe most of these are from using TextBox's, and 99% of the displayed text is produced from bindings (TextBlocks). I will try asking them again to post reproes if they find a way.
Other issues not sure whether related:
Build with a just cloned master
Are you using the nuget feed?
You can verify the current build by having a look at FontStretch.Stretch
if it exists you got the most recent build if not there is something wrong
Are you using the nuget feed?
I pulled code from master branch and build it directly. But I'm on Windows 11, the default system font of English may be different with Windows 10.
I just did this:
git clone https://github.com/AvaloniaUI/Avalonia.git
git submodule init
git submodule update
cd Avalonia\samples\ControlCatalog.NetCore
dotnet run
And I get the above result. I am also on Windows 11.
I figured out how to repro it: open ControlCatalog, then change your screen dpi. It behaves divergent under different scaling (mine is 250%).
Yes, reproduced here too. It seems that DPI resolution affects to the text vertical alignment:
I found a couple more:
Ahh okay so I guess unless I scale up the text it doesn't make sense to scale the bounding box
after #7693 -
Some selection bug, repro -
1.Take(Int32 length) at Avalonia.Media.TextFormatting.FormattedTextSource.CreateTextStyleRun(ReadOnlySlice
1 text, TextRunProperties defaultProperties, IReadOnlyList1 textModifier) at Avalonia.Media.TextFormatting.FormattedTextSource.GetTextRun(Int32 textSourceIndex) at Avalonia.Media.TextFormatting.TextFormatterImpl.TextRunEnumerator.MoveNext() at Avalonia.Media.TextFormatting.TextFormatterImpl.FetchTextRuns(ITextSource textSource, Int32 firstTextSourceIndex, TextEndOfLine& endOfLine, TextRange& textRange) at Avalonia.Media.TextFormatting.TextFormatterImpl.FormatLine(ITextSource textSource, Int32 firstTextSourceIndex, Double paragraphWidth, TextParagraphProperties paragraphProperties, TextLineBreak previousLineBreak) at Avalonia.Media.TextFormatting.TextLayout.CreateTextLines() at Avalonia.Media.TextFormatting.TextLayout..ctor(String text, Typeface typeface, Double fontSize, IBrush foreground, TextAlignment textAlignment, TextWrapping textWrapping, TextTrimming textTrimming, TextDecorationCollection textDecorations, FlowDirection flowDirection, Double maxWidth, Double maxHeight, Double lineHeight, Int32 maxLines, IReadOnlyList
1 textStyleOverrides)
at Avalonia.Controls.Presenters.TextPresenter.CreateTextLayoutInternal(Size constraint, String text, Typeface typeface, IReadOnlyList1 textStyleOverrides) at Avalonia.Controls.Presenters.TextPresenter.CreateTextLayout() at Avalonia.Controls.Presenters.TextPresenter.get_TextLayout() at Avalonia.Controls.Presenters.TextPresenter.MoveCaretToTextPosition(Int32 textPosition, Boolean trailingEdge) at Avalonia.Controls.Presenters.TextPresenter.set_CaretIndex(Int32 value) at Avalonia.Controls.Presenters.TextPresenter.<>c.<.cctor>b__23_1(TextPresenter o, Int32 v) at Avalonia.DirectProperty
2.InvokeSetter(IAvaloniaObject instance, BindingValue1 value) at Avalonia.AvaloniaObject.SetDirectValueUnchecked[T](DirectPropertyBase
1 property, BindingValue1 value) at Avalonia.AvaloniaObject.DirectBindingSubscription
1.OnNext(BindingValue1 value) at Avalonia.Reactive.SingleSubscriberObservableBase
1.PublishNext(T value)
at Avalonia.Reactive.TypedBindingAdapter1.OnNext(BindingValue
1 value)
at Avalonia.Reactive.SingleSubscriberObservableBase1.PublishNext(T value) at Avalonia.Reactive.BindingValueAdapter
1.OnNext(T value)
at Avalonia.Reactive.SingleSubscriberObservableBase1.PublishNext(T value) at Avalonia.Data.TemplateBinding.PublishValue() at Avalonia.Data.TemplateBinding.TemplatedParentPropertyChanged(Object sender, AvaloniaPropertyChangedEventArgs e) at Avalonia.AvaloniaObject.RaisePropertyChanged[T](AvaloniaPropertyChangedEventArgs
1 change)
at Avalonia.AvaloniaObject.RaisePropertyChanged[T](AvaloniaProperty1 property, Optional
1 oldValue, BindingValue1 newValue, BindingPriority priority) at Avalonia.AvaloniaObject.SetAndRaise[T](AvaloniaProperty
1 property, T& field, T value)
at Avalonia.Controls.TextBox.set_CaretIndex(Int32 value)
at Avalonia.Controls.TextBox.DeleteSelection(Boolean raiseTextChanged)
at Avalonia.Controls.TextBox.OnKeyDown(KeyEventArgs e)
at Blast.Controls.CustomTextBox.OnKeyDown(KeyEventArgs e) in C:\Git\Blast\Blast\Controls\CustomTextBox.cs:line 14
at Avalonia.Input.InputElement.<>c.<.cctor>b32_2(InputElement x, KeyEventArgs e)
at Avalonia.Interactivity.RoutedEvent1.<>c__DisplayClass2_0
1.2 args) at System.Reactive.AnonymousObserver
1.OnNextCore(T value) in //Rx.NET/Source/src/System.Reactive/AnonymousObserver.cs:line 67
at System.Reactive.ObserverBase1.OnNext(T value) in /_/Rx.NET/Source/src/System.Reactive/ObserverBase.cs:line 34 at System.Reactive.Subjects.Subject
1.OnNext(T value) in /_/Rx.NET/Source/src/System.Reactive/Subjects/Subject.cs:line 147
at Avalonia.Interactivity.RoutedEvent.InvokeRaised(Object sender, RoutedEventArgs e)
at Avalonia.Interactivity.EventRoute.RaiseEventImpl(RoutedEventArgs e)
at Avalonia.Interactivity.EventRoute.RaiseEvent(IInteractive source, RoutedEventArgs e)
at Avalonia.Interactivity.Interactive.RaiseEvent(RoutedEventArgs e)
at Avalonia.Input.KeyboardDevice.ProcessRawEvent(RawInputEventArgs e)
at Avalonia.Input.InputManager.ProcessInput(RawInputEventArgs e)
at Avalonia.Controls.TopLevel.HandleInput(RawInputEventArgs e)
at Avalonia.Win32.WindowImpl.AppWndProc(IntPtr hWnd, UInt32 msg, IntPtr wParam, IntPtr lParam)
at Avalonia.Win32.WindowImpl.WndProc(IntPtr hWnd, UInt32 msg, IntPtr wParam, IntPtr lParam)
at Avalonia.Win32.Interop.UnmanagedMethods.DispatchMessage(MSG& lpmsg)
at Avalonia.Win32.Win32Platform.RunLoop(CancellationToken cancellationToken)
at Avalonia.Threading.Dispatcher.MainLoop(CancellationToken cancellationToken)
at Avalonia.Controls.ApplicationLifetimes.ClassicDesktopStyleApplicationLifetime.Start(String[] args)
at Blast.Program.Main(String[] args) in C:\Git\Blast\Blast\Program.cs:line 263@Gillibald I'm testing the recently merged #7693, and I can still see a couple of issues:
Hitting Shift + End in the first line works fine. Doing that in the second line doesn't.
Using Shift + Ctrl + Right doesn't move the horizontal scroll right when the caret gets out of the viewport (however using standard cursor movement with keys works fine).
Thanks for you feedback will have a look
https://github.com/AvaloniaUI/Avalonia/pull/7746 should fix your last findings
@Gillibald yes, now issues are fixed, thanks!!
I found a couple of them more, but really small ones:
I found another bug:
It seems to split the surrogate pair
FlowDirection="RightToLeft
on TextBox
then Backwards
key isn't responding or responding wrong.if
FlowDirection="RightToLeft
onTextBox
thenBackwards
key isn't responding or responding wrong.
Wil have a look
Some issues I encountered during my work #7810:
[x] as @robloo said, many broken text in ControlCatalog
, even within ToolTip
, I guess this is the same problem.
[x] text in Flyouts
Tab exits outside the right border if is RTL FlowDirection:
[x] If you change the TextBox.FlowDirection
while run-time, the text is not aligned to the appropriate side, only if you click on the text it aligns the text:
@Gillibald, I found a missing feature.
https://user-images.githubusercontent.com/501613/159515582-c0a4f7e0-6e88-4799-a469-2a93a121fb4d.mov
https://user-images.githubusercontent.com/501613/159515549-88039fd5-3085-4427-8d2f-f200fa570aad.mov
I can't reproduce your last issue. Might be fixed already.
@Gillibald A lot of issues are related to the TextBox
functionality I notice. Would it be a good idea to just port the WPF TextBox to Avalonia now? I wouldn't think this would be too difficult considering all the lower-level text API's are now implemented. I know that wasn't possible before but now that WPF is open source and all the base pieces are there this makes the most sense to me.
@Gillibald I saw that you marked that the problems were fixed, I checked in front of your branch and did not see any change, you have not yet pushed the changes?
Edit: sorry, I had a problem compiling and thought it was compiled, I see it has been fixed.
@robloo Porting WPF's TextBox isn't possible at the moment because it requires the TextContainer. For reference: https://github.com/AvaloniaUI/Avalonia/blob/inlinesTheThird/src/Avalonia.Documents/Documents/TextContainer.cs
FlowDirection=RightToLeft
, Backwards
key deletes the previous letter as expected, but advances the cursor.
I can't reproduce your last issue. Might be fixed already.
@Gillibald, sorry I still reproduce the issue in LAST changes on master (commit [0483f9](https://github.com/AvaloniaUI/Avalonia/commit/0483f9bced0ea444b4b25e8b69659e54b80157e8)
). Should I test different changes?
The scenario is just clicking the second paragraph and hitting End/ key:
https://user-images.githubusercontent.com/501613/160274457-f1ec9f2e-222b-4288-8c89-5ae5da29b869.mp4
ToolTip
get wrong:
Edit: not related to flowDirection, it's always broken, in 175% dpi.
@danipen You always need to test against: https://github.com/AvaloniaUI/Avalonia/pull/7746
@Gillibald
[x] I'm seeing multiple instances where text length is not being measured correctly with latest master. The render length does not match the measured length somehow. This may be related to only certain characters like 'W'.
The tooltip is set to "Magenta"
The ComboBox text content is so long it's cutting off the right border
~CalendarDatePicker text with a 'W' (Wednesday) seems to consistently cause this. Other dates without a 'W' are measured correctly.~ Confirmed unrelated to text processing. Discussed below.
Please test against: https://github.com/AvaloniaUI/Avalonia/pull/7946
0.10.999-cibuild0020141-beta
@Gillibald there is some new bugs since #7946 merged.
TextBox
tab in ControlCatalog and try to select some text.I tested against #7946 what @robloo said, the problem is still there. it seems to be related also to scale (dpi), when the scale is 100%, some of the problems no longer exist.
This issue helps track bugs related to recent text processing changes. Feel free to post your findings here.