danwalmsley on win32-window-sizing-extended-client-area
fix window sizing when client a… (compare)
danwalmsley on change-default-system-chrome-hints
change default extend chrome hi… (compare)
danwalmsley on master
enumerate child windows and fin… whitespace. add unit tests. and 8 more (compare)
danwalmsley on enumerate-child-windows-before-closing
MarchingCube on enumerate-child-windows-before-closing
Added nullable annotations to C… Fix typo in doc for Visual.cs Merge branch 'master' into docs… and 4 more (compare)
MarchingCube on master
Added nullable annotations to C… Merge branch 'master' into feat… Merge pull request #5620 from A… (compare)
MarchingCube on control-nullability
danwalmsley on enumerate-child-windows-before-closing
use inline data. (compare)
MarchingCube on control-nullability
Branchless data index check Merge branch 'master' into chea… Fix typo in doc for Visual.cs and 4 more (compare)
danwalmsley on enumerate-child-windows-before-closing
add unit tests for window close… (compare)
var mwTemp = new MainWindowViewModel(this.sqrlInstance);
w.DataContext = mwTemp;
w.WindowStartupLocation = Avalonia.Controls.WindowStartupLocation.CenterOwner;
mwTemp.Content = new AskViewModel(this.sqrlInstance, this.Identity, serverResponse);
await w.ShowDialog(AvaloniaLocator.Current.GetService<MainWindow>());
NumericUpDown
and add a "Small Increment". Somethings are private though. So might have to copy the code and create a new one. My goal is to have a numeric textbox like in Blender: buttons either side of input; click and drag to increment/decrement; use a key modifier to use small increment; be able to do basic math.
So I changed the TextBox.Text
binding in my NumericUpDown
template to {TemplateBinding Text, Converter={x:Static cv:MathExpressionConverter.Instance }, Mode=TwoWay}
. And made my converter like so:
public class MathExpressionConverter : IValueConverter
{
public static readonly MathExpressionConverter Instance = new MathExpressionConverter();
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
return value;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
{
if (value is string input && MathExpressionParser.TryParseExpression(input, out var expression))
{
return expression.Compile().Invoke().ToString();
}
return new BindingNotification(new Exception("Invalid expression."), BindingErrorType.DataValidationError);
}
}
And I pretty much get what I want. It does the calculation without clearing the expression and when you press enter it commits the answer and displays the result. IDK how that works.
@grokys
@openmandev sounds like a bug. could you open an issue with a minimal repro and i'll try to fix it
WindowTitleBar
control. To make it easy to make custom chrome window
VisualRoot is Window window
?