These are chat archives for AvaloniaUI/Avalonia

30th
Sep 2017
Matthijs ter Woord
@mterwoord
Sep 30 2017 08:57
When building avalonia sources, I'm seeing a lot of file inclusion warnings (file not found, etc)
what's the idea behind that? needs cleaning?
Matthijs ter Woord
@mterwoord
Sep 30 2017 09:06
Ouch: #1170
Nikita Tsukanov
@kekekeks
Sep 30 2017 09:06
you probably need to update submodules or something
Matthijs ter Woord
@mterwoord
Sep 30 2017 09:07
ah, htis isn't on amster, but on 0.5.1
probably explains things..
sorry, didn't think of that.
Nikita Tsukanov
@kekekeks
Sep 30 2017 09:14
We need to make a new release soon-ish
Matthijs ter Woord
@mterwoord
Sep 30 2017 09:15
:)
making good progress (-ish) on the HueRingPicker
:)
Matthijs ter Woord
@mterwoord
Sep 30 2017 09:22
awesome. apart from some rendering issues (on start, on resize) it works!
afbeelding.png
Nikita Tsukanov
@kekekeks
Sep 30 2017 09:32
:+1:
Guys... You know, Wine now has a fancy-pancy Direct2D implementation that works on top of OpenGL...
I wonder if we could steal it
Matthijs ter Woord
@mterwoord
Sep 30 2017 09:33
steal implies its not allowed..
:)
i prefer to borrow things ;)
Nikita Tsukanov
@kekekeks
Sep 30 2017 09:34
You see, SharpDX already uses calli instruction for COM interop
So it shouldn't be that hard to get it working on Mono/.NETCore
The main problem would be to get a separate library with direct2d that doesn't depend on Wine
Matthijs ter Woord
@mterwoord
Sep 30 2017 09:50
Yuck. there's something going wrong with sizing of controls in a template (at least in 0.5.1)
Nikita Tsukanov
@kekekeks
Sep 30 2017 11:26
@grokys @jkoritzinsky I've found an issue with GTK
In GTK input, resize and other things like that
Have higher priority than Render
And I think there is no way to change that
GTK+ uses G_PRIORITY_HIGH_IDLE + 10 for resizing operations, and G_PRIORITY_HIGH_IDLE + 20 for redrawing operations. (This is done to ensure that any pending resizes are processed before any pending redraws, so that widgets are not redrawn twice unnecessarily.)
#define G_PRIORITY_DEFAULT 0
Use this for default priority event sources.
In GLib this priority is used when adding timeout functions with g_timeout_add(). In GDK this priority is used for events from the X server.
Matthijs ter Woord
@mterwoord
Sep 30 2017 11:41
Why is x:Key required for styles, even when i'm using the style using its selector?
Nikita Tsukanov
@kekekeks
Sep 30 2017 11:43
You are probably using resource dictionary instead of styles collection
Matthijs ter Woord
@mterwoord
Sep 30 2017 11:44
yes
awesome!
thanks!
Nikita Tsukanov
@kekekeks
Sep 30 2017 11:48
Hm, I guess I could add a custom dispatcher item with Render priority and can call gdk_window_process_updates manually
So it will have proper priority
Jurjen Biewenga
@JurjenBiewenga
Sep 30 2017 12:00
Is there a way to start windows async?
Nikita Tsukanov
@kekekeks
Sep 30 2017 12:01
Ehm, what?
Jurjen Biewenga
@JurjenBiewenga
Sep 30 2017 12:02
Open multiple windows that run async from each other
Matthijs ter Woord
@mterwoord
Sep 30 2017 12:02
run each window in its own thread?
Jurjen Biewenga
@JurjenBiewenga
Sep 30 2017 12:03
Was hoping just async methods would work
Matthijs ter Woord
@mterwoord
Sep 30 2017 12:03
async doesn't mean different threads (most of the time)
Jurjen Biewenga
@JurjenBiewenga
Sep 30 2017 12:04
I know
Nikita Tsukanov
@kekekeks
Sep 30 2017 12:04
We don't have multiple threads
that won't work anywhere but windows
Jurjen Biewenga
@JurjenBiewenga
Sep 30 2017 12:04
What's the preferred way to have multiple windows at the same time then?
Nikita Tsukanov
@kekekeks
Sep 30 2017 12:04
We could potentially make it work on Linux, if we implement our own Wayland and X11 backends
But that's quite a bit of work

What's the preferred way to have multiple windows at the same time then?

Ehm, just create a new one and call Show?

Matthijs ter Woord
@mterwoord
Sep 30 2017 12:05
@JurjenBiewenga you mean just multiple windows? just use .show
in wpf, you can put windows (and even controls..) on separate threads, but that's only needed for special cases
Jurjen Biewenga
@JurjenBiewenga
Sep 30 2017 12:08
Ah okay
Matthijs ter Woord
@mterwoord
Sep 30 2017 12:09
its needed for long sync processing, that's not possible on scondary thread. in general, that's only needed limited situatuions
most sync processing can happen using Task.Run
Jurjen Biewenga
@JurjenBiewenga
Sep 30 2017 12:12
Just doing show makes them not responsive or is that because they don't have any content?
Neil McAlister
@pingzing
Sep 30 2017 12:19
I'm trying to debug through Avalonia v0.5.1 to get a better idea of how it all fits together, but I can't seem to build from that commit--the ReactiveUI submodule appears to be missing the commit associated with the parent's commit. So, does anybody happen to just have the 0.5.1 PDBs lying around?
Nikita Tsukanov
@kekekeks
Sep 30 2017 12:21
Which commit is missing?
Jurjen Biewenga
@JurjenBiewenga
Sep 30 2017 12:22
Hmm, showing a window from a existing window(created through start) works, any way to show multiple windows without having to do that?
Nikita Tsukanov
@kekekeks
Sep 30 2017 12:22
Oh...
Neil McAlister
@pingzing
Sep 30 2017 12:22
Looks like f725c808b1d4c8457f0d3204e0a071aa462cd75
Nikita Tsukanov
@kekekeks
Sep 30 2017 12:22
You need to implement your own IClosable
And then use AppBuilder.bablabla().SetupWithoutStarting();
And then call Application.Run(yourclosable)
Jurjen Biewenga
@JurjenBiewenga
Sep 30 2017 12:23
Ah
Nikita Tsukanov
@kekekeks
Sep 30 2017 12:23
We probable need to add an overload with cancellation token or something
Jurjen Biewenga
@JurjenBiewenga
Sep 30 2017 12:23
I'll look into that
Matthijs ter Woord
@mterwoord
Sep 30 2017 12:26
@pingzing did you initialize the submodules?
Nikita Tsukanov
@kekekeks
Sep 30 2017 12:26
where did you get f725c808b1d4c8457f0d3204e0a071aa462cd75 from?
Neil McAlister
@pingzing
Sep 30 2017 12:26
oh, oops, copy-paste error. yeah, that's what I meant
missing the leading 3
Nikita Tsukanov
@kekekeks
Sep 30 2017 12:26
Well it should exist in that repo
Neil McAlister
@pingzing
Sep 30 2017 12:27
@mterwoord hm, I thought I had. let's make sure...
yeah, git submodule update results in Fetched in submodule path 'src/Avalonia.ReactiveUI/src', but it did not contain 3f725c808b1d4c8457f0d3204e0a071aa462cd75. Direct fetching of that commit failed.
git submodule init seems to have no effect when performed from the repo root
Nikita Tsukanov
@kekekeks
Sep 30 2017 12:29
Mkay, that's a known issue with github
If commit no longer exists in any branch
You are unable to fetch it
Change submodule url to this repo instead
Neil McAlister
@pingzing
Sep 30 2017 12:30
:+1: caaan do
Neil McAlister
@pingzing
Sep 30 2017 12:43
ah, it insisted it couldn't find that branch, but it's because the submodule was pointing to the actual ReactiveUI repo, not the Avalonia fork
I think I thunked it into obedience
Matthijs ter Woord
@mterwoord
Sep 30 2017 13:05
finally fixed my raspberry-skiasharp-buildscript :)
Matthijs ter Woord
@mterwoord
Sep 30 2017 13:13
Is there a way to get the Slider control working in reverse? I want it to be vertical (that's doable with orientation) but then have the high value on the upper side of the screen
Neil McAlister
@pingzing
Sep 30 2017 13:17
RotateTransform? =D
Matthijs ter Woord
@mterwoord
Sep 30 2017 13:17
RenderTransform correctly rotates the visible stuff, but not the interactions
so.. opening 7th VS instance.. :)
Jurjen Biewenga
@JurjenBiewenga
Sep 30 2017 13:21
Not sure how it is implemented but if it's a lerp then you can just put the high value first
Neil McAlister
@pingzing
Sep 30 2017 14:27
Almost got it to build. Now I'm getting a bunch of Error Could not load file or assembly 'Newtonsoft.Json, Version=6.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' or one of its dependencies. The system cannot find the file specified.
...and I'm pretty sure none of the projects even take a direct dependency on JSON.NET?
ideas?
Jurjen Biewenga
@JurjenBiewenga
Sep 30 2017 14:31
Try searching for the namespace?
I don't think it is used
Neil McAlister
@pingzing
Sep 30 2017 14:35
Actually, looks like it's coming from Shared/nuget.workaround.targets. Hm...
oh, looks like that's just the nuget task runner, okay
looks like the only file that so much as mentions newtonsoft is project.assets.json in \tests\Avalonia.RenderTests\obj-Skia
Matthijs ter Woord
@mterwoord
Sep 30 2017 15:02
@pingzing I'd proibably focus on master for diving into the sources..
Neil McAlister
@pingzing
Sep 30 2017 15:03
I'd like to, but I'm working on a UWP backend, which requires NetStandard1.4, which means 0.5.1 =/
Matthijs ter Woord
@mterwoord
Sep 30 2017 15:04
install vs 15.4 preview, it supports .net standard 2.0 for uwp
:)
(if you target fall update)
Neil McAlister
@pingzing
Sep 30 2017 15:04
yyyeah...that's the thing I was trying to avoid =P
Matthijs ter Woord
@mterwoord
Sep 30 2017 15:15
Is there a Closing event yet in avalonia?
Matthijs ter Woord
@mterwoord
Sep 30 2017 15:42
I'm starting a (simple) avalonia app using xinit. there app has a maximized window on start, but all i get on the device is a small window on the screen
any clues?
:)
Nikita Tsukanov
@kekekeks
Sep 30 2017 15:45
I think, I've figured out a proper way to make deferred renderer to work with GTK3
Jurjen Biewenga
@JurjenBiewenga
Sep 30 2017 20:13
@mterwoord can't you just set the window size to the working area size?
Nikita Tsukanov
@kekekeks
Sep 30 2017 23:21
@grokys I've managed to get DeferredRenderer working with GTK3 and Linux, but something weird is going on with layout
Nikita Tsukanov
@kekekeks
Sep 30 2017 23:52
Actually, I can reproduce that layout issue on master
AvaloniaUI/Avalonia#1171