[Python.NET] WPF or other GUI with PythonNet & Clingo

David Epstein <[email protected]> Tue, 3 May 2022 10:43:19 +0000
Newsgroups gmane.comp.python.dotnet
Message-ID <DM5PR1201MB0187EAA0CD6BAB399F297B7DBEC09@DM5PR1201MB0187.namprd12.prod.outlook.com>
--===============7296648706395146040==
Content-Language: en-US
Content-Type: multipart/alternative;
	boundary="_000_DM5PR1201MB0187EAA0CD6BAB399F297B7DBEC09DM5PR1201MB0187_"

--_000_DM5PR1201MB0187EAA0CD6BAB399F297B7DBEC09DM5PR1201MB0187_
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Hi folks!

This is my first post. In short, I'd like to know whether it is a good idea=
 to use PythonNet within a MVVM framework to glue the models (that rely on =
a Python package) to the user interface's view models and views (that rely =
on C# and WPF controls). If it is a good idea, I'd welcome advice (e.g. wor=
king with PythonNet within a Visual Studio C# project). If it is not a good=
 idea, I'd welcome alternatives (e.g. Python GUIs with desktop functionalit=
y like docking).

Here are the details. I'm creating a graphical, desktop, turn-based game/si=
mulation based on the logic programming system, Clingo<https://potassco.org=
/>, which is accessible from Python (via import clingo<https://pypi.org/pro=
ject/clingo/>). While other language bindings exist for Clingo (including a=
 nascent C# one<https://github.com/NEKERAFA/clingo-cs>), the Python binding=
 appears to be the most complete and most popular.

However, I've only created GUI's using C# frameworks (WPF & Xamarin.Forms).=
 Since I'd like this application to include docking, data grid, rich-text e=
ditor, tooltips, and other Windows desktop staples, I'm inclined to use WPF=
. I may have access to DevExpress' WPF controls<https://www.devexpress.com/=
products/net/controls/wpf/> and technical support, the latter of which migh=
t require me to use C# (not sure).

What do you think?

Thank you,
-david

--_000_DM5PR1201MB0187EAA0CD6BAB399F297B7DBEC09DM5PR1201MB0187_
Content-Type: text/html; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<html>
<head>
<meta http-equiv=3D"Content-Type" content=3D"text/html; charset=3Diso-8859-=
1">
<style type=3D"text/css" style=3D"display:none;"> P {margin-top:0;margin-bo=
ttom:0;} </style>
</head>
<body dir=3D"ltr">
<div class=3D"elementToProof" style=3D"font-family:Calibri,Helvetica,sans-s=
erif; font-size:12pt; color:rgb(0,0,0)">
Hi folks! <br>
</div>
<div class=3D"elementToProof" style=3D"font-family:Calibri,Helvetica,sans-s=
erif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div class=3D"elementToProof" style=3D"font-family:Calibri,Helvetica,sans-s=
erif; font-size:12pt; color:rgb(0,0,0)">
This is my first post. In short, I'd like to know whether it is a good idea=
 to use PythonNet within a MVVM framework to glue the models (that rely on =
a Python package) to the user interface's view models and views (that rely =
on C# and WPF controls). If it is
 a good idea, I'd welcome advice (e.g. working with PythonNet within a Visu=
al Studio C# project). If it is
<i>not</i> a good idea, I'd welcome alternatives (e.g. Python GUIs with des=
ktop functionality like docking).<br>
</div>
<div class=3D"elementToProof" style=3D"font-family:Calibri,Helvetica,sans-s=
erif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div class=3D"elementToProof" style=3D"font-family:Calibri,Helvetica,sans-s=
erif; font-size:12pt; color:rgb(0,0,0)">
Here are the details. I'm creating a graphical, desktop, turn-based game/si=
mulation based on the logic programming system,
<a href=3D"https://potassco.org/" data-auth=3D"NotApplicable" title=3D"http=
s://potassco.org/">
Clingo</a>, which is accessible from Python (via <a href=3D"https://pypi.or=
g/project/clingo/" data-auth=3D"NotApplicable" title=3D"https://pypi.org/pr=
oject/clingo/">
import clingo</a>). While other language bindings exist for Clingo (includi=
ng a <a href=3D"https://github.com/NEKERAFA/clingo-cs" data-auth=3D"NotAppl=
icable" title=3D"https://github.com/NEKERAFA/clingo-cs">
nascent C# one</a>), the Python binding appears to be the most complete and=
 most popular.<br>
</div>
<div class=3D"elementToProof" style=3D"font-family:Calibri,Helvetica,sans-s=
erif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div class=3D"elementToProof" style=3D"font-family:Calibri,Helvetica,sans-s=
erif; font-size:12pt; color:rgb(0,0,0)">
However, I've only created GUI's using C# frameworks (WPF &amp; Xamarin.For=
ms). Since I'd like this application to include docking, data grid, rich-te=
xt editor, tooltips, and other Windows desktop staples, I'm inclined to use=
 WPF. I may have access to
<a href=3D"https://www.devexpress.com/products/net/controls/wpf/" title=3D"=
https://www.devexpress.com/products/net/controls/wpf/">
DevExpress' WPF controls</a> and technical support, the latter of which mig=
ht require me to use C# (not sure).</div>
<div class=3D"elementToProof" style=3D"font-family:Calibri,Helvetica,sans-s=
erif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div class=3D"elementToProof" style=3D"font-family:Calibri,Helvetica,sans-s=
erif; font-size:12pt; color:rgb(0,0,0)">
What do you think?<br>
</div>
<div class=3D"elementToProof" style=3D"font-family:Calibri,Helvetica,sans-s=
erif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div class=3D"elementToProof" style=3D"font-family:Calibri,Helvetica,sans-s=
erif; font-size:12pt; color:rgb(0,0,0)">
Thank you,</div>
<div class=3D"elementToProof" style=3D"font-family:Calibri,Helvetica,sans-s=
erif; font-size:12pt; color:rgb(0,0,0)">
-david<br>
</div>
</body>
</html>

--_000_DM5PR1201MB0187EAA0CD6BAB399F297B7DBEC09DM5PR1201MB0187_--

--===============7296648706395146040==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
PythonNet mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3/lists/pythonnet.python.org/
Member address: [email protected]

--===============7296648706395146040==--