Skip to content

Instantly share code, notes, and snippets.

View ghost1372's full-sized avatar
Focusing

Mahdi Hosseini ghost1372

Focusing
View GitHub Profile
@ghost1372
ghost1372 / App.xaml
Created April 20, 2023 12:00
WinUIGallery-TitleBar
<ResourceDictionary.ThemeDictionaries>
<ResourceDictionary x:Key="Light">
<SolidColorBrush x:Key="NavigationViewExpandedPaneBackground" Color="Transparent" />
</ResourceDictionary>
<ResourceDictionary x:Key="Dark">
<SolidColorBrush x:Key="NavigationViewExpandedPaneBackground" Color="Transparent" />
</ResourceDictionary>
<ResourceDictionary x:Key="HighContrast">
<SolidColorBrush x:Key="NavigationViewExpandedPaneBackground" Color="Transparent" />
</ResourceDictionary>
@ghost1372
ghost1372 / publish.yml
Last active May 15, 2024 12:06
I use this action to publish project, compress to Zip and upload to GitHub release
name: "Publish"
on:
push:
tags:
- "v*"
env:
PROJECT_PATH: WpfApp6/WpfApp6.csproj
ZIP_PATH: WpfApp6/bin/Release/net5.0-windows/win-x86/publish/WpfApp6-Portable.zip
@ghost1372
ghost1372 / Geometry.xaml
Last active June 17, 2022 06:05
More than 3200 icons in Geometry Format based on FontAwesome, ModernUI, Icons8, MaterialLight
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<Geometry x:Key="CalendarGeometry">M377.897477 116.291025l265.298718 0 0 47.459125-265.298718 0 0-47.459125ZM888.317416 116.291025 748.229288 116.291025l0 47.459125 123.54866 0c18.167626 0 32.894732 14.727106 32.894732 32.894732l0 92.92987L115.42936 289.574752l0-92.92987c0-18.167626 14.727106-32.894732 32.894732-32.894732l123.54866 0 0-47.459125L131.776437 116.291025c-35.244356 0-63.814389 28.571056-63.814389 63.815412l0.004093 713.966329c0 35.243333 28.571056 63.814389 63.814389 63.814389l756.540979 0c35.244356 0 63.814389-28.571056 63.814389-63.815412l-0.004093-713.966329C952.131805 144.861058 923.560749 116.291025 888.317416 116.291025zM904.67268 337.033877l0 540.498398c0 18.167626-14.727106 32.894732-32.894732 32.894732L148.324092 910.427007c-18.167626 0-32.894732-14.727106-32.894732-32.894732L115.42936 337.033877 904.67268 337.033877zM300.659736 64.801927l47.4
@ghost1372
ghost1372 / InteractionTriggers.xaml
Created September 21, 2018 08:03
Interaction.Triggers for change in controls when selected
<i:Interaction.Triggers>
<i:EventTrigger EventName="Click">
<ei:ChangePropertyAction PropertyName="Style" Value="{StaticResource ButtonDanger}" />
</i:EventTrigger>
</i:Interaction.Triggers>
using System.ComponentModel;
using System.Globalization;
using System.Resources;
using System.Windows.Data;
public class TranslationSource
: INotifyPropertyChanged
{
private static readonly TranslationSource instance = new TranslationSource();