wildgums / orc.controls Goto Github PK
View Code? Open in Web Editor NEWTimespan, DateTime and various other controls
License: Other
Timespan, DateTime and various other controls
License: Other
Dependabot couldn't reach https://wildgums.myget.org/F/wildgums/api/v3/index.json as it timed out.
Is https://wildgums.myget.org/F/wildgums/api/v3/index.json accessible over the internet? If it is then this may be a transitory issue and can be ignored - Dependabot will close it on its next successful update run.
Color range seems to have a wrong offset.
Dependabot encountered the following error when parsing your .dependabot/config.yml
:
The property '#/update_configs/0/automerged_updates/0' of type object did not match one or more of the required schemas
The property '#/update_configs/0/automerged_updates/1' of type object did not match one or more of the required schemas
The property '#/update_configs/0/automerged_updates/2' of type object did not match one or more of the required schemas
The property '#/update_configs/0/automerged_updates/3' of type object did not match one or more of the required schemas
Please update the config file to conform with Dependabot's specification.
You can mention @dependabot in the comments below to contact the Dependabot team.
Sometimes, one wants to use LazyLoading in the TabControl, but still preload 1 or 2 tabs. We should allow for this scenario.
Hi,
Look at this code:
if (e.Key == Key.Up && AllTextSelected) { OnUpDown(1); e.Handled = true; } if (e.Key == Key.Down) { OnUpDown(-1); e.Handled = true; }
This is found in NumericTextBox::OnPreviewKeyDown(KeyEventArgs e) method.
Is it ok that only up key checks whether all text is selected and down key is not checking ?
I can fix it if you wish.
orccontrols:PinnableToolTipService.Placement="Top"
to the element in PinnableToolTipView.xaml
Platform:
.NET version: CLR v4.0.30319 '(NET 452 I think)
Orc.Controls 3.1.0
That I can move the tooltip ;)
$exception | {"Value cannot be null.\r\nParameter name: otherVisual"} | System.ArgumentNullException
Backtrace:
at System.Windows.Media.Visual.FindCommonVisualAncestor(DependencyObject otherVisual)
at System.Windows.Media.Visual.TransformToVisual(Visual visual)
at Orc.Controls.PinnableToolTip.GetTranslatedPoints(FrameworkElement frameworkElement) in C:\Users\Drachenkatze\Source\Repos\Orc.Controls\src\Orc.Controls\Controls\PinnableToolTips\Controls\PinnableToolTip.cs:line 581
at Orc.Controls.PinnableToolTip.GetPosition() in C:\Users\Drachenkatze\Source\Repos\Orc.Controls\src\Orc.Controls\Controls\PinnableToolTips\Controls\PinnableToolTip.cs:line 288
at Orc.Controls.ControlAdorner.ArrangeOverride(Size finalSize) in C:\Users\Drachenkatze\Source\Repos\Orc.Controls\src\Orc.Controls\Controls\PinnableToolTips\Adorners\ControlAdorner.cs:line 90
at System.Windows.FrameworkElement.ArrangeCore(Rect finalRect)
at System.Windows.UIElement.Arrange(Rect finalRect)
at System.Windows.Documents.AdornerLayer.ArrangeOverride(Size finalSize)
at System.Windows.FrameworkElement.ArrangeCore(Rect finalRect)
at System.Windows.UIElement.Arrange(Rect finalRect)
at System.Windows.ContextLayoutManager.UpdateLayout()
at System.Windows.ContextLayoutManager.UpdateLayoutCallback(Object arg)
at System.Windows.Media.MediaContext.FireInvokeOnRenderCallbacks()
at System.Windows.Media.MediaContext.RenderMessageHandlerCore(Object resizedCompositionTarget)
at System.Windows.Media.MediaContext.RenderMessageHandler(Object resizedCompositionTarget)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)```
Platform:
.NET version: 4.0
The theme for Orc.Control DateTimePicker and DatePicker shall not impact on default controls (non Orc.Controls)
The togglebutton or listboxitem default styles are impacted in a negative way (become invisible)
By inlining the default theme from Orc.Controls and commenting out following resource dictionary references:
<!--ResourceDictionary Source="/Orc.Controls;component/Controls/DatePicker/Themes/DatePickerControl.generic.xaml" /> <ResourceDictionary Source="/Orc.Controls;component/Controls/DateTimePicker/Themes/DateTimePickerControl.generic.xaml" /-->
Then bad behaviour disappears. So these xaml are not boxed.
The Behaviour was ok in version 1.2.0, version 1.3.0 introduced the bad behaviour reported here (tested)
if my system's short date format defines month as MMM
(which is a valid month format)
DateTimeFormatInfoExtensions.SetMonthFormat
fails since it hard-checks if the month format length is > 2 and raises an exception
ref : https://github.com/WildGums/Orc.Controls/blob/develop/src/Orc.Controls/Extensions/DateTimeFormatInfoExtensions.cs#L138
it's also worthy to note that MMMM is also a valid month modifier
suggested solution would be to increase the limit to length > 4 instead of 2
list of some valid DateTime formats : https://www.c-sharpcorner.com/blogs/date-and-time-format-in-c-sharp-programming1
In Orc.Wizard we have a control named "breadcrumb", but this name is misleading (wrong). We would like to extract it into a separate control in Orc.Controls so we can use it (even without the wizard):
We want this control to:
Then we want to have 2 subparts:
Should have:
Should have:
This way we can change the icon based on the state, etc.
Please think about the API before writing code and discuss any potential issues you are seeing. Note that we want to replace the "breadcrumb" in Orc.Wizard by this control so it should at least contain that functionality.
This style should use the accent color markup extensions so it represents a specific theme.
Discovered this when using TimeSpanControl
<Style ... BasedOn="{StaticResource {x:Type orc:TimeSpanControl}}">
wont work because x:keys are not set for default styles.
Inside WPF default styles the keys are set like this:
<Style x:Key="{x:Type TextBox}"
BasedOn="{StaticResource {x:Type TextBoxBase}}"
TargetType="{x:Type TextBox}">
</Style>
So the mentioned code would work for them. I think this project should follow this convention.
Catel v5.12.6 uses Microsoft.Xaml.Behaviors.Wpf for all services.
Orc.Controls.DropDownButton v3.4.1 still uses System.Windows.Interactivity.
Please fix it.
Let me know when you start working on this one. It requires custom theming based on dark / light theming (we need a different kind of blue in dark mode).
What component is this issue occurring in?
LogViewer
Compiles from sources, downloaded from repository today, 02/May
Windows 10 x64
Working
Catel.IoC.TypeNotRegisteredException
HResult=0x80131500
Сообщение = The specified type 'Orc.Controls.IApplicationLogFilterGroupService, Orc.Controls, Version=4.0.0.0, Culture=neutral, PublicKeyToken=null' is not registered or could not be constructed. Please register type before using it. The type 'Orc.Controls.IApplicationLogFilterGroupService, Orc.Controls, Version=4.0.0.0, Culture=neutral, PublicKeyToken=null' is not registered
Источник = Catel.Core
Трассировка стека:
at Catel.IoC.ServiceLocator.ThrowTypeNotRegisteredException(Type type, String message)
at Catel.IoC.ServiceLocator.CreateServiceInstanceWrapper(Func`2 createServiceFunc, ServiceLocatorRegistration registration)
at Catel.IoC.ServiceLocator.ResolveTypeFromKnownContainer(ServiceInfo serviceInfo)
at Catel.IoC.ServiceLocator.ResolveType(Type serviceType, Object tag)
at Catel.IoC.TypeFactory.TryCreateToConstruct(Type typeToConstruct, ConstructorInfo constructor, Object tag, Object[] parameters, Boolean checkConstructor, Boolean hasMoreConstructorsLeft, TypeMetaData typeMetaData)
at Catel.IoC.TypeFactory.CreateInstanceWithSpecifiedParameters(Type typeToConstruct, Object tag, Object[] parameters, Boolean autoCompleteDependencies)
at Catel.IoC.TypeFactory.CreateInstanceWithTag(Type typeToConstruct, Object tag)
at Catel.MVVM.ViewModelFactory.CreateViewModel(Type viewModelType, Object dataContext, Object tag)
at Catel.MVVM.Providers.LogicBase.ConstructViewModelUsingArgumentOrDefaultConstructor(Object injectionObject, Type viewModelType)
at Catel.MVVM.Providers.UserControlLogic.d__69.MoveNext()
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Catel.MVVM.Providers.UserControlLogic.d__56.MoveNext()
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Catel.MVVM.Providers.LogicBase.d__128.MoveNext()
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
at System.Windows.Threading.DispatcherOperation.InvokeImpl()
at MS.Internal.CulturePreservingExecutionContext.CallbackWrapper(Object obj)
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
at MS.Internal.CulturePreservingExecutionContext.Run(CulturePreservingExecutionContext executionContext, ContextCallback callback, Object state)
at System.Windows.Threading.DispatcherOperation.Invoke()
at System.Windows.Threading.Dispatcher.ProcessQueue()
at System.Windows.Threading.Dispatcher.WndProcHook(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
at System.Windows.Threading.Dispatcher.LegacyInvokeImpl(DispatcherPriority priority, TimeSpan timeout, Delegate method, Object args, Int32 numArgs)
at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam)
at MS.Win32.UnsafeNativeMethods.DispatchMessage(MSG& msg)
at System.Windows.Threading.Dispatcher.PushFrameImpl(DispatcherFrame frame)
at System.Windows.Application.RunDispatcher(Object ignore)
at System.Windows.Application.RunInternal(Window window)
at Orc.Controls.Example.App.Main()
Изначально это исключение было создано в этом стеке вызовов:
Catel.IoC.ServiceLocator.ThrowTypeNotRegisteredException(System.Type, string)
Catel.IoC.ServiceLocator.CreateServiceInstanceWrapper(System.Func<Catel.IoC.ServiceLocatorRegistration, object>, Catel.IoC.ServiceLocatorRegistration)
Catel.IoC.ServiceLocator.ResolveTypeFromKnownContainer(Catel.IoC.ServiceLocator.ServiceInfo)
Catel.IoC.ServiceLocator.ResolveType(System.Type, object)
Catel.IoC.TypeFactory.TryCreateToConstruct(System.Type, System.Reflection.ConstructorInfo, object, object[], bool, bool, Catel.IoC.TypeFactory.TypeMetaData)
Catel.IoC.TypeFactory.CreateInstanceWithSpecifiedParameters(System.Type, object, object[], bool)
Catel.IoC.TypeFactory.CreateInstanceWithTag(System.Type, object)
Catel.MVVM.ViewModelFactory.CreateViewModel(System.Type, object, object)
Catel.MVVM.Providers.LogicBase.ConstructViewModelUsingArgumentOrDefaultConstructor(object, System.Type)
Catel.MVVM.Providers.UserControlLogic.UpdateDataContextToUseViewModelAsync(object)
...
[Стек вызовов обрезан]
I have this code:
public class Settings : SavableModelBase<Settings>
{
//fody properties
public string AccountsPath {get; set;}
[ExcludeFromSerialization]
public string[] Accounts {get; set;}
protected override void OnPropertyChanged(AdvancedPropertyChangedEventArgs e)
{
switch (e.PropertyName)
{
case nameof(AccountsPath):
LoadAccounts();
break;
}
base.OnPropertyChanged(e);
}
private void LoadAccounts()
{
if (!File.Exists(AccountsPath)) return;
Accounts = File.ReadAllLines(AccountsPath);
}
}
And I have settings datawindow with OpenFilePickerView binded to Settings.AccountsPath.
When user choosed file property changed firing, but if user choosed same file again (edited in notepad, for example) property changed not firing. Can i fix that or i should manually update file if it is edited?
What component is this issue occurring in?
DateTimePicker
? actual
Windows 10
copy the Date and Time
you can solve it with:
if (formatInfo.SecondPosition.HasValue)
{
parts.Add(new KeyValuePair<int, string>(formatInfo.SecondPosition.Value, dateTime.Second.ToString(NumberFormatHelper.GetFormat(formatInfo.SecondFormat.Length))));
}
you can solve it with:
if (parts.Count > 5)
{
builder.Append(parts[5].Value);
builder.Append(formatInfo.Separator6);
}
A NullReferenceException
occurs at LogViewerControl.xaml.cs#L248 at application startup. This happens because OnViewModelLogMessage
can be called before UpdateControl
if no control properties are changed from the default values.
With this code (sample code modified):
namespace Orc.Controls.Examples.ViewModels
{
using System.Collections.Generic;
using Catel.MVVM;
public class FilterBoxViewModel : ViewModelBase
{
#region Constructors
public FilterBoxViewModel()
{
FilterSource = new List<KeyValuePair<string, string>>
{
new KeyValuePair<string, string>("1", "abcd"),
new KeyValuePair<string, string>("2", "basdf"),
new KeyValuePair<string, string>("3", "bwerr"),
new KeyValuePair<string, string>("4", "oiydd"),
new KeyValuePair<string, string>("5", "klhhs"),
new KeyValuePair<string, string>("6", "sdfhi"),
};
ListOfPersons = new List<KeyValuePair<string, string>>
{
new KeyValuePair<string, string>("1", "Bill"),
new KeyValuePair<string, string>("2", "Steve"),
new KeyValuePair<string, string>("3", "John"),
new KeyValuePair<string, string>("4", "Paul"),
new KeyValuePair<string, string>("5", "George"),
new KeyValuePair<string, string>("6", "Ringo"),
};
}
#endregion
#region Properties
public List<KeyValuePair<string, string>> FilterSource { get; private set; }
public List<KeyValuePair<string, string>> ListOfPersons { get; private set; }
public string FilterText { get; set; }
#endregion
}
}
and this XAML:
<orc:FilterBoxControl Width="200" HorizontalAlignment="Left" PropertyName="Value" Margin="6,4,6,4" FilterSource="{Binding ListOfPersons}" Text="{Binding FilterText}" Watermark="Filter"/>
it appears the FilterSource is bounded to list FilterSource, and not list ListOfPersons as expected. It looks like the FilterSource is hard coded bounded to a property FilterSource.
Is this a bug or it is by design or I m not using it properly?
I think we can just it derive from {StaticResource Orc.Styles.TabControl}
and it should look good out of the box.
I've documented an issue I have with the FilterBox control in the attached pdf (with screen shots). This, I think, explains succinctly the issue. It's a very quick read. The orc:FilterBoxControl simply does not show, neither in design mode nor in debug mode.
This may be a newbie problem. I appreciate any help. Thank you kindly.
Issue FilterBoxControl.pdf
To introduce a new control to Orc's Control Ecosystem called a MultiSelect ComboBox. As shown below it can be either one of these variations (or both).
The premise of this feature is to introduce the supported concept of multiple item selection to a ComboBox. This would allow the implementer to leverage support for multi-value collections (such as a collection of strings, integers and so forth) in an easy to use form.
At a high-level the API for the control would have the following exposed properties:
Property Name | Property Type | Binding Mode |
---|---|---|
ItemsSource | IEnumerable | Two-Way |
SelectedItems | IEnumerable | Two-Way |
DisplayMemberPath | string | One-Way to Source |
SelectedValueMemberPath | string | One Way to Source |
DisplayMemberPath
and SelectedValueMemberPath
are leveraged properties for when the underlying ItemsSource
type is of either IDictionary<TKey, TValue>
or IEnumerable<KeyValuePair<TKey, TValue>>
or a collection composing of business objects rather than primitive types.
If DisplayMemberPath
is not defined then the ToString()
method of the underlying type is called.
If SelectValueMemberPath
is not defined, then the underlying type is used.
This is all preliminary and it is possible that feature development may be accelerated using some of the foundation of the ColorLegend control. I am willing to take ownership of this feature development once my time allows. The request for the feature is not due to a needed business requirement but rather a desire to contribute to the library.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.