Questions tagged [wpf]

Windows Presentation Foundation (WPF) is part of the Microsoft .NET framework used to create rich client user experiences for Windows application.

33 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
5
votes
0answers
56 views

Finding collision between two Images using virtual Rect

I'm making a game. There is a turtle and lots of platforms it can walk on. It walks on its own and you can change the direction it is walking. I implemented a working logic, but I think it can be ...
4
votes
0answers
84 views

License-holder editing application

I am building a WPF (Windows Presentation Foundation) application. And I'm trying to use the MVVM (Model–View–ViewModel) design pattern. It's fascinating and rewarding, even though it seems overly ...
4
votes
0answers
369 views

Media player subtitles in WPF - Part 2 Handlers and notifications

This is a continuation of Part 1. In this question I will present you with a single class which is the most crucial component of the whole system, it's responsible for firing notifications whenever a ...
4
votes
0answers
5k views

WPF CustomControl Image Button that changes with state and does not use ControlTemplate

Note: See Verticle WPF icon button that used Segoe MDL2 font for icon for an example using Segoe MDL2 for the icons. I need a button that changes appearance based on the state of a Boolean. A ...
4
votes
0answers
3k views

WPF MVVM Dialog with Prism, MahApps.Metro

I am building a Metro-themed WPF application with MVVM approach using Prism and MahApps.Metro. I have to show a custom dialog from view model. Currently, I am using ...
4
votes
0answers
210 views

Swapping Tab Order

The code I have below swaps two tabs around. This is done through creating an array, deleting all tabs and then recreating them which seems very inefficient to me. ...
3
votes
0answers
321 views

Simple MVVM Navigation for WPF in c#

I have been learning MVVM and I have decided to create a small framework for simple MVVM programs I can make in the future. This program provides navigation between a main menu, settings menu, start ...
3
votes
0answers
990 views

OpenCv webcam streaming class for WPF

My goal is to make a class that wraps the complexity of OpenCvSharp implementation to show a webcam streaming into a WPF Image. ...
3
votes
0answers
325 views

WPF: An implementation of INotifyDataErrorInfo

An abstract base class which derives from the ObservableObject (MvvmLight), implementing the INotifyDataErrorInfo interface. ...
3
votes
0answers
248 views

Object pooling in WPF

In a WPF project I'm working on, often multiple objects reuse the same AnimationTimeline, to smooth that out I made an ...
3
votes
0answers
399 views

Media player in WPF - Event binding

I recently started making a media player, this is the first time I'm using WPF and I found that most project are utilizing the MVVM architectural pattern, I haven't used that one either but I decided ...
3
votes
0answers
364 views

WPF Prism DelegateCommand Setup

I am currently in the process of learning WPF Prism and I have four buttons that I want to all go to the same place but with a different value being passed depending on which button has been pressed. ...
3
votes
0answers
228 views

Extension for BindableBase that can dispose the old value of a property if that property implements IDisposable and is not null

I am interested in hearing opinions on this. I need a way to dispose the old value of a property in a way that's compatible with BindableBase. Specifically, I have ...
2
votes
0answers
74 views

WPF DataGrid Column FIltering using Behaviors

This is the simplest implementation of the 'DataGridBehavior' Class for column Filtering I could come up with: ...
2
votes
0answers
432 views

Tic Tac Toe game using WPF+MVVM

I am looking for some advice on how to create a new ViewModel within an already existing ViewModel. I am creating a Tic Tac Toe game, to improve my knowledge of the MVVM pattern, WPF and C#. I am ...
2
votes
0answers
196 views

C# Learning MVVM by creating a Login functionality

I am trying to get my head around how MVVM pattern works. Would like to hear some reviews if I am implementing it correctly. View ...
2
votes
0answers
275 views

Is this an acceptable MVVM Model with IEditableObject implementation?

I'm trying to follow MVVM pattern in a VB.net WPF application, and I would like to implement IEditableObject. Is this code acceptable for an MVVM application? In ...
2
votes
0answers
104 views

Simple Data Entry Application in WPF xaml UI

I made a simple data entry application in WPF MVVM and was just hoping for some input as I am pretty new to WPF . I have done the same application using winforms. Now I have recreated the same ...
2
votes
0answers
1k views

Setting the Owner property on a modal dialog in WPF/MVVM using a Func

I'm looking to solve the problem of setting the Owner property on modal dialogs in WPF, while using IoC and MVVM patterns. I've seen (and written) all sorts of ...
2
votes
0answers
410 views

Switching between ViewModels using IoC in a MVVM WPF application

I have a project that uses Caliburn.Micro to implement the MVVM pattern. For IoC, I am using MEF. All the ViewModels are marked ...
2
votes
0answers
271 views

Initializing child windows in MvvM

I have a MvvM application that is working very fine. However I am not sure if I'm writing a clean code, especially the part handling child windows with their controller. So to begin, i have this ...
2
votes
0answers
1k views

Prism find active/existing ViewModel

I was facing an issue where I want to retrieve existing/active ViewModels from the Prism runtime. Here's the code I've done to achieve it: ...
2
votes
0answers
208 views

Fractal renderer in WPF

This was made mostly for fun, but also to practice. I'm generally looking for feedback on how to make the code run faster, any obvious mistakes I'm making in regards to using WPF, which I'm not at ...
2
votes
0answers
302 views

Control for displaying error messages

I am working on a WPF application consisting of a tree view and multiple "view parts" that display details about the selected node. The content of the view parts are loaded asynchronously which may ...
2
votes
0answers
1k views

Hotkey-System for command-based WPF applications

I wrote a Hotkey-System for command-based WPF applications. Could you please take a look at my code (even if it consists of multiple classes :P). I am mainly interested in following things: How ...
2
votes
0answers
189 views

Keep clean SimpleIoc initialization when reusing UserControl

Originally I had ChildUserControl inside ParentUserControl inside MainWindow with this view-...
2
votes
0answers
214 views

BackgroundWorker in WPF executing multiple methods

I've implemented a BackgroundWorker in my WPF app. My code is pretty ugly though. I've been told to write as little as redundant code as possible. IS there some generic Method I could employ to reduce ...
1
vote
0answers
30 views

User control displaying data which refreshes every 0.125 seconds

I have the following data bindings set up: ...
1
vote
0answers
70 views

Tiny app to track working time on Jira tickets

I'm a .NET intern. For my project management we work with Jira and we have to track real working time on a ticket to log the work and compare it to the original estimate. For this purpose I have ...
1
vote
0answers
247 views

A ViewModel build with ReactiveUI 8 to get web images

This is a practice application that I built to learn Rx.Net & RxUI. It follows the MVVM pattern and is written in C# with WPF. Here is a link to a question I asked during the development, which ...
1
vote
0answers
595 views

WPF "Glowing" button user control

I have created a "wrapper" for a button that "pulses" until the user presses the button. The implementation that I came up with is below, but I'm sure there's a better approach. ...
1
vote
0answers
2k views

Using IoC Container with Entity Framework Repository Pattern

I am using WPF with Entity Framework 6 (DB first), Caliburn.Micro, and MEF. I am trying to ...
0
votes
0answers
32 views

Sort Data in Categories to display in Treeview

I import a list of objects from an JSON file and want to display it in a WPF TreeView Control. The Data looks like this: ...