Search found 216 matches

  • 1
  • 2
  • 3
  • 4
  • 5
  • 22
by ai_enabled
30 Apr 2019, 14:28
Forum: General Discussion
Replies: 3
Views: 122

Any way to override the style from code?

Hi guys, so we're making a moddable game and one of the requests is—API to override a certain Style resource with another Style resource (from another resource dictionary or created right in the code). Is there any way to do this? We have a fairly monolithic DefaultStyles.xaml file so overriding it ...
by ai_enabled
12 Apr 2019, 15:07
Forum: General Discussion
Replies: 6
Views: 148

Re: Setting the text hinting

Thanks for your responses. Yes, the scroll value is changed every frame. Well, it doesn't look bad, I just wanted to be sure the pixel snapping is disabled :-) Support for TextOptions.TextHintingMode="Animated" would have helped me to ensure this, but if you're 100% certain the snapping is disabled ...
by ai_enabled
12 Apr 2019, 15:04
Forum: General Discussion
Replies: 5
Views: 137

Re: Xenko Integration

Yes, I'm going to update NoesisGUI Wrapper to add support for 2.2 on this weekend. Recently I was extremely busy with the game launch so it was not updated in time.
by ai_enabled
06 Apr 2019, 02:38
Forum: General Discussion
Replies: 6
Views: 148

Re: Setting the text hinting

I definitely can see the text glimmering more than it should when it slowly scrolls up. Especially noticeable on 1920x1080 or lower resolution screen. And the text is very clear every frame. So I assume the snapping is applied every frame as the text is not actually animated via storyboard, but the ...
by ai_enabled
04 Apr 2019, 02:21
Forum: General Discussion
Replies: 6
Views: 148

Re: Setting the text hinting

Right, this seems to be related to the text snapping. I've tried to disable SnapsToDevicePixel but can't see any difference. We're not actually using animation but simply adjusting the vertical scroll offset every frame. This way it's much easier to program the complex behavior we need (so it's poss...
by ai_enabled
27 Mar 2019, 20:29
Forum: General Discussion
Replies: 6
Views: 148

Setting the text hinting

Hi guys, I'm curious if there is a way to apply something like WPF TextOptions.TextHintingMode="Animated" to the textblock? The use case is the credits menu in the game - it's scrolled every frame on some small distance. The text produces some flickering while scrolling - I suppose this is related t...
by ai_enabled
08 Mar 2019, 12:20
Forum: General Discussion
Replies: 6
Views: 274

Re: Localization / Translation approaches

So, at the end you are not following the approach #4 right? Because you remove all x:Static entries at runtime. That's correct. In the runtime they're replaced with the actual string (a const value acquired via Reflection) but this is a hack until you implement an x:Static support for const/static ...
by ai_enabled
06 Mar 2019, 01:26
Forum: General Discussion
Replies: 6
Views: 274

Re: Localization / Translation approaches

Thank you, guys, for your replies! I've thought a lot on the best approach and settled with the approach #4 ("x:Static approach to reference C# const string") from my first post. We also need to localize strings in C# code and I really dislike .NET resources files (I mean *.resx; if we have chosen t...
by ai_enabled
27 Jan 2019, 00:35
Forum: General Discussion
Replies: 5
Views: 148

Re: Several Horizontal.Aligments do not cooperate

Yes, you can use a variable:
var button1 = new Button(...);
DockPanel.SetDock(button1, Dock.Left))
_panel.Children.Add(button1);
And with Grid - you can add more column definitions at any time. It's often the way to go - a simple yet powerful layout.

Regards!
by ai_enabled
26 Jan 2019, 13:10
Forum: General Discussion
Replies: 5
Views: 148

Re: Several Horizontal.Aligments do not cooperate

First, you're incorrectly using DockPanel. If you want elements to properly align ("dock") in it you need to assign DockPanel.Dock attached property (from C# it's set as DockPanel.SetDock(control, Dock.Left)). For example see https://docs.microsoft.com/en-us/dotnet/api/system.windows.controls.dockpa...
  • 1
  • 2
  • 3
  • 4
  • 5
  • 22