Showing preview only (499K chars total). Download the full file or copy to clipboard to get everything.
Repository: Gniang/RoundedTB
Branch: master
Commit: b78e5d6e9ced
Files: 39
Total size: 480.3 KB
Directory structure:
gitextract_2jsysl7i/
├── .gitattributes
├── .github/
│ └── workflows/
│ └── ci.yml
├── .gitignore
├── AnalysisReport.sarif
├── LICENSE
├── PackagingProject/
│ ├── Package.appxmanifest
│ └── RoundedTB.Package.wapproj
├── README.md
├── RoundedTB/
│ ├── .editorconfig
│ ├── AboutWindow.xaml
│ ├── AboutWindow.xaml.cs
│ ├── App.config
│ ├── App.xaml
│ ├── App.xaml.cs
│ ├── AppBars.cs
│ ├── Background.cs
│ ├── EnumerableExtensions.cs
│ ├── FodyWeavers.xml
│ ├── IAppVisibility.cs
│ ├── Infobox.xaml
│ ├── Infobox.xaml.cs
│ ├── Interaction.cs
│ ├── LocalPInvoke.cs
│ ├── MainWindow.xaml
│ ├── MainWindow.xaml.cs
│ ├── MonitorStuff.cs
│ ├── Properties/
│ │ ├── AssemblyInfo.cs
│ │ ├── Resources.Designer.cs
│ │ ├── Resources.resx
│ │ ├── Settings.Designer.cs
│ │ └── Settings.settings
│ ├── RoundedTB.csproj
│ ├── Taskbar.cs
│ ├── TaskbarEffect.xaml
│ ├── TaskbarEffect.xaml.cs
│ ├── Types.cs
│ └── app.manifest
├── RoundedTB.sln
└── upgrade-assistant.clef
================================================
FILE CONTENTS
================================================
================================================
FILE: .gitattributes
================================================
###############################################################################
# Set default behavior to automatically normalize line endings.
###############################################################################
* text=auto
###############################################################################
# Set default behavior for command prompt diff.
#
# This is need for earlier builds of msysgit that does not have it on by
# default for csharp files.
# Note: This is only used by command line
###############################################################################
#*.cs diff=csharp
###############################################################################
# Set the merge driver for project and solution files
#
# Merging from the command prompt will add diff markers to the files if there
# are conflicts (Merging from VS is not affected by the settings below, in VS
# the diff markers are never inserted). Diff markers may cause the following
# file extensions to fail to load in VS. An alternative would be to treat
# these files as binary and thus will always conflict and require user
# intervention with every merge. To do so, just uncomment the entries below
###############################################################################
#*.sln merge=binary
#*.csproj merge=binary
#*.vbproj merge=binary
#*.vcxproj merge=binary
#*.vcproj merge=binary
#*.dbproj merge=binary
#*.fsproj merge=binary
#*.lsproj merge=binary
#*.wixproj merge=binary
#*.modelproj merge=binary
#*.sqlproj merge=binary
#*.wwaproj merge=binary
###############################################################################
# behavior for image files
#
# image files are treated as binary by default.
###############################################################################
#*.jpg binary
#*.png binary
#*.gif binary
###############################################################################
# diff behavior for common document formats
#
# Convert binary document formats to text before diffing them. This feature
# is only available from the command line. Turn it on by uncommenting the
# entries below.
###############################################################################
#*.doc diff=astextplain
#*.DOC diff=astextplain
#*.docx diff=astextplain
#*.DOCX diff=astextplain
#*.dot diff=astextplain
#*.DOT diff=astextplain
#*.pdf diff=astextplain
#*.PDF diff=astextplain
#*.rtf diff=astextplain
#*.RTF diff=astextplain
================================================
FILE: .github/workflows/ci.yml
================================================
name: release
on:
push:
jobs:
build:
name: build-windows
runs-on: windows-2022
steps:
- name: Checkout
uses: actions/checkout@v3
with:
submodules: recursive
- name: Set up MSBuild
uses: microsoft/setup-msbuild@v1
- name: NuGet Restore
run: |
cd ${{ github.workspace }}
nuget restore RoundedTB.sln
- name: Build
run: |
cd ${{ github.workspace }}
msbuild "-property:Configuration=Release" -t:RoundedTB
- name: Add commit hash to output folder
run: |
Rename-Item -Path ".\RoundedTB\bin\Release" -NewName "RoundedTB-$(git rev-parse --short ${{ github.sha }})"
- name: Upload artifacts
uses: actions/upload-artifact@v3
with:
name: rtb-artifacts
path: |
.\RoundedTB\bin\RoundedTB-*\
================================================
FILE: .gitignore
================================================
## Ignore Visual Studio temporary files, build results, and
## files generated by popular Visual Studio add-ons.
##
## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore
# User-specific files
*.rsuser
*.suo
*.user
*.userosscache
*.sln.docstates
# User-specific files (MonoDevelop/Xamarin Studio)
*.userprefs
# Mono auto generated files
mono_crash.*
# Build results
[Dd]ebug/
[Dd]ebugPublic/
[Rr]elease/
[Rr]eleases/
x64/
x86/
[Ww][Ii][Nn]32/
[Aa][Rr][Mm]/
[Aa][Rr][Mm]64/
bld/
[Bb]in/
[Oo]bj/
[Oo]ut/
[Ll]og/
[Ll]ogs/
# Visual Studio 2015/2017 cache/options directory
.vs/
# Uncomment if you have tasks that create the project's static files in wwwroot
#wwwroot/
# Visual Studio 2017 auto generated files
Generated\ Files/
# MSTest test Results
[Tt]est[Rr]esult*/
[Bb]uild[Ll]og.*
# NUnit
*.VisualState.xml
TestResult.xml
nunit-*.xml
# Build Results of an ATL Project
[Dd]ebugPS/
[Rr]eleasePS/
dlldata.c
# Benchmark Results
BenchmarkDotNet.Artifacts/
# .NET Core
project.lock.json
project.fragment.lock.json
artifacts/
# ASP.NET Scaffolding
ScaffoldingReadMe.txt
# StyleCop
StyleCopReport.xml
# Files built by Visual Studio
*_i.c
*_p.c
*_h.h
*.ilk
*.meta
*.obj
*.iobj
*.pch
*.pdb
*.ipdb
*.pgc
*.pgd
*.rsp
*.sbr
*.tlb
*.tli
*.tlh
*.tmp
*.tmp_proj
*_wpftmp.csproj
*.log
*.vspscc
*.vssscc
.builds
*.pidb
*.svclog
*.scc
# Chutzpah Test files
_Chutzpah*
# Visual C++ cache files
ipch/
*.aps
*.ncb
*.opendb
*.opensdf
*.sdf
*.cachefile
*.VC.db
*.VC.VC.opendb
# Visual Studio profiler
*.psess
*.vsp
*.vspx
*.sap
# Visual Studio Trace Files
*.e2e
# TFS 2012 Local Workspace
$tf/
# Guidance Automation Toolkit
*.gpState
# ReSharper is a .NET coding add-in
_ReSharper*/
*.[Rr]e[Ss]harper
*.DotSettings.user
# TeamCity is a build add-in
_TeamCity*
# DotCover is a Code Coverage Tool
*.dotCover
# AxoCover is a Code Coverage Tool
.axoCover/*
!.axoCover/settings.json
# Coverlet is a free, cross platform Code Coverage Tool
coverage*.json
coverage*.xml
coverage*.info
# Visual Studio code coverage results
*.coverage
*.coveragexml
# NCrunch
_NCrunch_*
.*crunch*.local.xml
nCrunchTemp_*
# MightyMoose
*.mm.*
AutoTest.Net/
# Web workbench (sass)
.sass-cache/
# Installshield output folder
[Ee]xpress/
# DocProject is a documentation generator add-in
DocProject/buildhelp/
DocProject/Help/*.HxT
DocProject/Help/*.HxC
DocProject/Help/*.hhc
DocProject/Help/*.hhk
DocProject/Help/*.hhp
DocProject/Help/Html2
DocProject/Help/html
# Click-Once directory
publish/
# Publish Web Output
*.[Pp]ublish.xml
*.azurePubxml
# Note: Comment the next line if you want to checkin your web deploy settings,
# but database connection strings (with potential passwords) will be unencrypted
*.pubxml
*.publishproj
# Microsoft Azure Web App publish settings. Comment the next line if you want to
# checkin your Azure Web App publish settings, but sensitive information contained
# in these scripts will be unencrypted
PublishScripts/
# NuGet Packages
*.nupkg
# NuGet Symbol Packages
*.snupkg
# The packages folder can be ignored because of Package Restore
**/[Pp]ackages/*
# except build/, which is used as an MSBuild target.
!**/[Pp]ackages/build/
# Uncomment if necessary however generally it will be regenerated when needed
#!**/[Pp]ackages/repositories.config
# NuGet v3's project.json files produces more ignorable files
*.nuget.props
*.nuget.targets
# Microsoft Azure Build Output
csx/
*.build.csdef
# Microsoft Azure Emulator
ecf/
rcf/
# Windows Store app package directories and files
AppPackages/
BundleArtifacts/
Package.StoreAssociation.xml
_pkginfo.txt
*.appx
*.appxbundle
*.appxupload
# Visual Studio cache files
# files ending in .cache can be ignored
*.[Cc]ache
# but keep track of directories ending in .cache
!?*.[Cc]ache/
# Others
ClientBin/
~$*
*~
*.dbmdl
*.dbproj.schemaview
*.jfm
*.pfx
*.publishsettings
orleans.codegen.cs
# Including strong name files can present a security risk
# (https://github.com/github/gitignore/pull/2483#issue-259490424)
#*.snk
# Since there are multiple workflows, uncomment next line to ignore bower_components
# (https://github.com/github/gitignore/pull/1529#issuecomment-104372622)
#bower_components/
# RIA/Silverlight projects
Generated_Code/
# Backup & report files from converting an old project file
# to a newer Visual Studio version. Backup files are not needed,
# because we have git ;-)
_UpgradeReport_Files/
Backup*/
UpgradeLog*.XML
UpgradeLog*.htm
ServiceFabricBackup/
*.rptproj.bak
# SQL Server files
*.mdf
*.ldf
*.ndf
# Business Intelligence projects
*.rdl.data
*.bim.layout
*.bim_*.settings
*.rptproj.rsuser
*- [Bb]ackup.rdl
*- [Bb]ackup ([0-9]).rdl
*- [Bb]ackup ([0-9][0-9]).rdl
# Microsoft Fakes
FakesAssemblies/
# GhostDoc plugin setting file
*.GhostDoc.xml
# Node.js Tools for Visual Studio
.ntvs_analysis.dat
node_modules/
# Visual Studio 6 build log
*.plg
# Visual Studio 6 workspace options file
*.opt
# Visual Studio 6 auto-generated workspace file (contains which files were open etc.)
*.vbw
# Visual Studio LightSwitch build output
**/*.HTMLClient/GeneratedArtifacts
**/*.DesktopClient/GeneratedArtifacts
**/*.DesktopClient/ModelManifest.xml
**/*.Server/GeneratedArtifacts
**/*.Server/ModelManifest.xml
_Pvt_Extensions
# Paket dependency manager
.paket/paket.exe
paket-files/
# FAKE - F# Make
.fake/
# CodeRush personal settings
.cr/personal
# Python Tools for Visual Studio (PTVS)
__pycache__/
*.pyc
# Cake - Uncomment if you are using it
# tools/**
# !tools/packages.config
# Tabs Studio
*.tss
# Telerik's JustMock configuration file
*.jmconfig
# BizTalk build output
*.btp.cs
*.btm.cs
*.odx.cs
*.xsd.cs
# OpenCover UI analysis results
OpenCover/
# Azure Stream Analytics local run output
ASALocalRun/
# MSBuild Binary and Structured Log
*.binlog
# NVidia Nsight GPU debugger configuration file
*.nvuser
# MFractors (Xamarin productivity tool) working folder
.mfractor/
# Local History for Visual Studio
.localhistory/
# BeatPulse healthcheck temp database
healthchecksdb
# Backup folder for Package Reference Convert tool in Visual Studio 2017
MigrationBackup/
# Ionide (cross platform F# VS Code tools) working folder
.ionide/
# Fody - auto-generated XML schema
FodyWeavers.xsd
/RoundedTB/RoundedTBEmi.ico
================================================
FILE: AnalysisReport.sarif
================================================
{
"$schema": "https://schemastore.azurewebsites.net/schemas/json/sarif-2.1.0-rtm.5.json",
"version": "2.1.0",
"runs": [
{
"tool": {
"driver": {
"name": "Dependency Analysis",
"semanticVersion": "0.3.261602",
"informationUri": "https://docs.microsoft.com/en-us/dotnet/core/porting/upgrade-assistant-overview",
"rules": [
{
"id": "UA105",
"name": "PackageToBeDeleted",
"fullDescription": {
"text": "Packages that need to be deleted in order to upgrade the project to chosen TFM"
},
"helpUri": "https://docs.microsoft.com/en-us/dotnet/core/porting/upgrade-assistant-overview"
},
{
"id": "UA106",
"name": "PackageToBeAdded",
"fullDescription": {
"text": "Packages that need to be added in order to upgrade the project to chosen TFM"
},
"helpUri": "https://docs.microsoft.com/en-us/dotnet/core/porting/upgrade-assistant-overview"
}
]
}
},
"results": [
{
"ruleId": "UA105",
"message": {
"text": "Package Microsoft.Windows.SDK.Contracts, Version=10.0.18362.2005 needs to be deleted."
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "file:///C:/Users/Torch/source/repos/RoundedTB/RoundedTB/RoundedTB.csproj"
},
"region": {}
}
}
]
},
{
"ruleId": "UA105",
"message": {
"text": "Package System.Runtime.WindowsRuntime, Version=4.6.0 needs to be deleted."
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "file:///C:/Users/Torch/source/repos/RoundedTB/RoundedTB/RoundedTB.csproj"
},
"region": {}
}
}
]
},
{
"ruleId": "UA105",
"message": {
"text": "Package System.Runtime.WindowsRuntime.UI.Xaml, Version=4.6.0 needs to be deleted."
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "file:///C:/Users/Torch/source/repos/RoundedTB/RoundedTB/RoundedTB.csproj"
},
"region": {}
}
}
]
},
{
"ruleId": "UA105",
"message": {
"text": "Package System.ValueTuple, Version=4.5.0 needs to be deleted."
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "file:///C:/Users/Torch/source/repos/RoundedTB/RoundedTB/RoundedTB.csproj"
},
"region": {}
}
}
]
},
{
"ruleId": "UA106",
"message": {
"text": "Package Microsoft.DotNet.UpgradeAssistant.Extensions.Default.Analyzers, Version=0.3.261602 needs to be added."
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "file:///C:/Users/Torch/source/repos/RoundedTB/RoundedTB/RoundedTB.csproj"
},
"region": {}
}
}
]
},
{
"ruleId": "UA106",
"message": {
"text": "Package Microsoft.Windows.Compatibility, Version=6.0.0 needs to be added."
},
"locations": [
{
"physicalLocation": {
"artifactLocation": {
"uri": "file:///C:/Users/Torch/source/repos/RoundedTB/RoundedTB/RoundedTB.csproj"
},
"region": {}
}
}
]
}
],
"columnKind": "utf16CodeUnits"
},
{
"tool": {
"driver": {
"name": "API Upgradability",
"semanticVersion": "0.3.261602",
"informationUri": "https://docs.microsoft.com/en-us/dotnet/core/porting/upgrade-assistant-overview"
}
},
"results": [],
"columnKind": "utf16CodeUnits"
},
{
"tool": {
"driver": {
"name": "Component Analysis",
"semanticVersion": "0.3.261602",
"informationUri": "https://docs.microsoft.com/en-us/dotnet/core/porting/upgrade-assistant-overview"
}
},
"results": [],
"columnKind": "utf16CodeUnits"
}
]
}
================================================
FILE: LICENSE
================================================
GNU GENERAL PUBLIC LICENSE
Version 3, 29 June 2007
Copyright (C) 2007 Free Software Foundation, Inc. <https://fsf.org/>
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
The GNU General Public License is a free, copyleft license for
software and other kinds of works.
The licenses for most software and other practical works are designed
to take away your freedom to share and change the works. By contrast,
the GNU General Public License is intended to guarantee your freedom to
share and change all versions of a program--to make sure it remains free
software for all its users. We, the Free Software Foundation, use the
GNU General Public License for most of our software; it applies also to
any other work released this way by its authors. You can apply it to
your programs, too.
When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
them if you wish), that you receive source code or can get it if you
want it, that you can change the software or use pieces of it in new
free programs, and that you know you can do these things.
To protect your rights, we need to prevent others from denying you
these rights or asking you to surrender the rights. Therefore, you have
certain responsibilities if you distribute copies of the software, or if
you modify it: responsibilities to respect the freedom of others.
For example, if you distribute copies of such a program, whether
gratis or for a fee, you must pass on to the recipients the same
freedoms that you received. You must make sure that they, too, receive
or can get the source code. And you must show them these terms so they
know their rights.
Developers that use the GNU GPL protect your rights with two steps:
(1) assert copyright on the software, and (2) offer you this License
giving you legal permission to copy, distribute and/or modify it.
For the developers' and authors' protection, the GPL clearly explains
that there is no warranty for this free software. For both users' and
authors' sake, the GPL requires that modified versions be marked as
changed, so that their problems will not be attributed erroneously to
authors of previous versions.
Some devices are designed to deny users access to install or run
modified versions of the software inside them, although the manufacturer
can do so. This is fundamentally incompatible with the aim of
protecting users' freedom to change the software. The systematic
pattern of such abuse occurs in the area of products for individuals to
use, which is precisely where it is most unacceptable. Therefore, we
have designed this version of the GPL to prohibit the practice for those
products. If such problems arise substantially in other domains, we
stand ready to extend this provision to those domains in future versions
of the GPL, as needed to protect the freedom of users.
Finally, every program is threatened constantly by software patents.
States should not allow patents to restrict development and use of
software on general-purpose computers, but in those that do, we wish to
avoid the special danger that patents applied to a free program could
make it effectively proprietary. To prevent this, the GPL assures that
patents cannot be used to render the program non-free.
The precise terms and conditions for copying, distribution and
modification follow.
TERMS AND CONDITIONS
0. Definitions.
"This License" refers to version 3 of the GNU General Public License.
"Copyright" also means copyright-like laws that apply to other kinds of
works, such as semiconductor masks.
"The Program" refers to any copyrightable work licensed under this
License. Each licensee is addressed as "you". "Licensees" and
"recipients" may be individuals or organizations.
To "modify" a work means to copy from or adapt all or part of the work
in a fashion requiring copyright permission, other than the making of an
exact copy. The resulting work is called a "modified version" of the
earlier work or a work "based on" the earlier work.
A "covered work" means either the unmodified Program or a work based
on the Program.
To "propagate" a work means to do anything with it that, without
permission, would make you directly or secondarily liable for
infringement under applicable copyright law, except executing it on a
computer or modifying a private copy. Propagation includes copying,
distribution (with or without modification), making available to the
public, and in some countries other activities as well.
To "convey" a work means any kind of propagation that enables other
parties to make or receive copies. Mere interaction with a user through
a computer network, with no transfer of a copy, is not conveying.
An interactive user interface displays "Appropriate Legal Notices"
to the extent that it includes a convenient and prominently visible
feature that (1) displays an appropriate copyright notice, and (2)
tells the user that there is no warranty for the work (except to the
extent that warranties are provided), that licensees may convey the
work under this License, and how to view a copy of this License. If
the interface presents a list of user commands or options, such as a
menu, a prominent item in the list meets this criterion.
1. Source Code.
The "source code" for a work means the preferred form of the work
for making modifications to it. "Object code" means any non-source
form of a work.
A "Standard Interface" means an interface that either is an official
standard defined by a recognized standards body, or, in the case of
interfaces specified for a particular programming language, one that
is widely used among developers working in that language.
The "System Libraries" of an executable work include anything, other
than the work as a whole, that (a) is included in the normal form of
packaging a Major Component, but which is not part of that Major
Component, and (b) serves only to enable use of the work with that
Major Component, or to implement a Standard Interface for which an
implementation is available to the public in source code form. A
"Major Component", in this context, means a major essential component
(kernel, window system, and so on) of the specific operating system
(if any) on which the executable work runs, or a compiler used to
produce the work, or an object code interpreter used to run it.
The "Corresponding Source" for a work in object code form means all
the source code needed to generate, install, and (for an executable
work) run the object code and to modify the work, including scripts to
control those activities. However, it does not include the work's
System Libraries, or general-purpose tools or generally available free
programs which are used unmodified in performing those activities but
which are not part of the work. For example, Corresponding Source
includes interface definition files associated with source files for
the work, and the source code for shared libraries and dynamically
linked subprograms that the work is specifically designed to require,
such as by intimate data communication or control flow between those
subprograms and other parts of the work.
The Corresponding Source need not include anything that users
can regenerate automatically from other parts of the Corresponding
Source.
The Corresponding Source for a work in source code form is that
same work.
2. Basic Permissions.
All rights granted under this License are granted for the term of
copyright on the Program, and are irrevocable provided the stated
conditions are met. This License explicitly affirms your unlimited
permission to run the unmodified Program. The output from running a
covered work is covered by this License only if the output, given its
content, constitutes a covered work. This License acknowledges your
rights of fair use or other equivalent, as provided by copyright law.
You may make, run and propagate covered works that you do not
convey, without conditions so long as your license otherwise remains
in force. You may convey covered works to others for the sole purpose
of having them make modifications exclusively for you, or provide you
with facilities for running those works, provided that you comply with
the terms of this License in conveying all material for which you do
not control copyright. Those thus making or running the covered works
for you must do so exclusively on your behalf, under your direction
and control, on terms that prohibit them from making any copies of
your copyrighted material outside their relationship with you.
Conveying under any other circumstances is permitted solely under
the conditions stated below. Sublicensing is not allowed; section 10
makes it unnecessary.
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
No covered work shall be deemed part of an effective technological
measure under any applicable law fulfilling obligations under article
11 of the WIPO copyright treaty adopted on 20 December 1996, or
similar laws prohibiting or restricting circumvention of such
measures.
When you convey a covered work, you waive any legal power to forbid
circumvention of technological measures to the extent such circumvention
is effected by exercising rights under this License with respect to
the covered work, and you disclaim any intention to limit operation or
modification of the work as a means of enforcing, against the work's
users, your or third parties' legal rights to forbid circumvention of
technological measures.
4. Conveying Verbatim Copies.
You may convey verbatim copies of the Program's source code as you
receive it, in any medium, provided that you conspicuously and
appropriately publish on each copy an appropriate copyright notice;
keep intact all notices stating that this License and any
non-permissive terms added in accord with section 7 apply to the code;
keep intact all notices of the absence of any warranty; and give all
recipients a copy of this License along with the Program.
You may charge any price or no price for each copy that you convey,
and you may offer support or warranty protection for a fee.
5. Conveying Modified Source Versions.
You may convey a work based on the Program, or the modifications to
produce it from the Program, in the form of source code under the
terms of section 4, provided that you also meet all of these conditions:
a) The work must carry prominent notices stating that you modified
it, and giving a relevant date.
b) The work must carry prominent notices stating that it is
released under this License and any conditions added under section
7. This requirement modifies the requirement in section 4 to
"keep intact all notices".
c) You must license the entire work, as a whole, under this
License to anyone who comes into possession of a copy. This
License will therefore apply, along with any applicable section 7
additional terms, to the whole of the work, and all its parts,
regardless of how they are packaged. This License gives no
permission to license the work in any other way, but it does not
invalidate such permission if you have separately received it.
d) If the work has interactive user interfaces, each must display
Appropriate Legal Notices; however, if the Program has interactive
interfaces that do not display Appropriate Legal Notices, your
work need not make them do so.
A compilation of a covered work with other separate and independent
works, which are not by their nature extensions of the covered work,
and which are not combined with it such as to form a larger program,
in or on a volume of a storage or distribution medium, is called an
"aggregate" if the compilation and its resulting copyright are not
used to limit the access or legal rights of the compilation's users
beyond what the individual works permit. Inclusion of a covered work
in an aggregate does not cause this License to apply to the other
parts of the aggregate.
6. Conveying Non-Source Forms.
You may convey a covered work in object code form under the terms
of sections 4 and 5, provided that you also convey the
machine-readable Corresponding Source under the terms of this License,
in one of these ways:
a) Convey the object code in, or embodied in, a physical product
(including a physical distribution medium), accompanied by the
Corresponding Source fixed on a durable physical medium
customarily used for software interchange.
b) Convey the object code in, or embodied in, a physical product
(including a physical distribution medium), accompanied by a
written offer, valid for at least three years and valid for as
long as you offer spare parts or customer support for that product
model, to give anyone who possesses the object code either (1) a
copy of the Corresponding Source for all the software in the
product that is covered by this License, on a durable physical
medium customarily used for software interchange, for a price no
more than your reasonable cost of physically performing this
conveying of source, or (2) access to copy the
Corresponding Source from a network server at no charge.
c) Convey individual copies of the object code with a copy of the
written offer to provide the Corresponding Source. This
alternative is allowed only occasionally and noncommercially, and
only if you received the object code with such an offer, in accord
with subsection 6b.
d) Convey the object code by offering access from a designated
place (gratis or for a charge), and offer equivalent access to the
Corresponding Source in the same way through the same place at no
further charge. You need not require recipients to copy the
Corresponding Source along with the object code. If the place to
copy the object code is a network server, the Corresponding Source
may be on a different server (operated by you or a third party)
that supports equivalent copying facilities, provided you maintain
clear directions next to the object code saying where to find the
Corresponding Source. Regardless of what server hosts the
Corresponding Source, you remain obligated to ensure that it is
available for as long as needed to satisfy these requirements.
e) Convey the object code using peer-to-peer transmission, provided
you inform other peers where the object code and Corresponding
Source of the work are being offered to the general public at no
charge under subsection 6d.
A separable portion of the object code, whose source code is excluded
from the Corresponding Source as a System Library, need not be
included in conveying the object code work.
A "User Product" is either (1) a "consumer product", which means any
tangible personal property which is normally used for personal, family,
or household purposes, or (2) anything designed or sold for incorporation
into a dwelling. In determining whether a product is a consumer product,
doubtful cases shall be resolved in favor of coverage. For a particular
product received by a particular user, "normally used" refers to a
typical or common use of that class of product, regardless of the status
of the particular user or of the way in which the particular user
actually uses, or expects or is expected to use, the product. A product
is a consumer product regardless of whether the product has substantial
commercial, industrial or non-consumer uses, unless such uses represent
the only significant mode of use of the product.
"Installation Information" for a User Product means any methods,
procedures, authorization keys, or other information required to install
and execute modified versions of a covered work in that User Product from
a modified version of its Corresponding Source. The information must
suffice to ensure that the continued functioning of the modified object
code is in no case prevented or interfered with solely because
modification has been made.
If you convey an object code work under this section in, or with, or
specifically for use in, a User Product, and the conveying occurs as
part of a transaction in which the right of possession and use of the
User Product is transferred to the recipient in perpetuity or for a
fixed term (regardless of how the transaction is characterized), the
Corresponding Source conveyed under this section must be accompanied
by the Installation Information. But this requirement does not apply
if neither you nor any third party retains the ability to install
modified object code on the User Product (for example, the work has
been installed in ROM).
The requirement to provide Installation Information does not include a
requirement to continue to provide support service, warranty, or updates
for a work that has been modified or installed by the recipient, or for
the User Product in which it has been modified or installed. Access to a
network may be denied when the modification itself materially and
adversely affects the operation of the network or violates the rules and
protocols for communication across the network.
Corresponding Source conveyed, and Installation Information provided,
in accord with this section must be in a format that is publicly
documented (and with an implementation available to the public in
source code form), and must require no special password or key for
unpacking, reading or copying.
7. Additional Terms.
"Additional permissions" are terms that supplement the terms of this
License by making exceptions from one or more of its conditions.
Additional permissions that are applicable to the entire Program shall
be treated as though they were included in this License, to the extent
that they are valid under applicable law. If additional permissions
apply only to part of the Program, that part may be used separately
under those permissions, but the entire Program remains governed by
this License without regard to the additional permissions.
When you convey a copy of a covered work, you may at your option
remove any additional permissions from that copy, or from any part of
it. (Additional permissions may be written to require their own
removal in certain cases when you modify the work.) You may place
additional permissions on material, added by you to a covered work,
for which you have or can give appropriate copyright permission.
Notwithstanding any other provision of this License, for material you
add to a covered work, you may (if authorized by the copyright holders of
that material) supplement the terms of this License with terms:
a) Disclaiming warranty or limiting liability differently from the
terms of sections 15 and 16 of this License; or
b) Requiring preservation of specified reasonable legal notices or
author attributions in that material or in the Appropriate Legal
Notices displayed by works containing it; or
c) Prohibiting misrepresentation of the origin of that material, or
requiring that modified versions of such material be marked in
reasonable ways as different from the original version; or
d) Limiting the use for publicity purposes of names of licensors or
authors of the material; or
e) Declining to grant rights under trademark law for use of some
trade names, trademarks, or service marks; or
f) Requiring indemnification of licensors and authors of that
material by anyone who conveys the material (or modified versions of
it) with contractual assumptions of liability to the recipient, for
any liability that these contractual assumptions directly impose on
those licensors and authors.
All other non-permissive additional terms are considered "further
restrictions" within the meaning of section 10. If the Program as you
received it, or any part of it, contains a notice stating that it is
governed by this License along with a term that is a further
restriction, you may remove that term. If a license document contains
a further restriction but permits relicensing or conveying under this
License, you may add to a covered work material governed by the terms
of that license document, provided that the further restriction does
not survive such relicensing or conveying.
If you add terms to a covered work in accord with this section, you
must place, in the relevant source files, a statement of the
additional terms that apply to those files, or a notice indicating
where to find the applicable terms.
Additional terms, permissive or non-permissive, may be stated in the
form of a separately written license, or stated as exceptions;
the above requirements apply either way.
8. Termination.
You may not propagate or modify a covered work except as expressly
provided under this License. Any attempt otherwise to propagate or
modify it is void, and will automatically terminate your rights under
this License (including any patent licenses granted under the third
paragraph of section 11).
However, if you cease all violation of this License, then your
license from a particular copyright holder is reinstated (a)
provisionally, unless and until the copyright holder explicitly and
finally terminates your license, and (b) permanently, if the copyright
holder fails to notify you of the violation by some reasonable means
prior to 60 days after the cessation.
Moreover, your license from a particular copyright holder is
reinstated permanently if the copyright holder notifies you of the
violation by some reasonable means, this is the first time you have
received notice of violation of this License (for any work) from that
copyright holder, and you cure the violation prior to 30 days after
your receipt of the notice.
Termination of your rights under this section does not terminate the
licenses of parties who have received copies or rights from you under
this License. If your rights have been terminated and not permanently
reinstated, you do not qualify to receive new licenses for the same
material under section 10.
9. Acceptance Not Required for Having Copies.
You are not required to accept this License in order to receive or
run a copy of the Program. Ancillary propagation of a covered work
occurring solely as a consequence of using peer-to-peer transmission
to receive a copy likewise does not require acceptance. However,
nothing other than this License grants you permission to propagate or
modify any covered work. These actions infringe copyright if you do
not accept this License. Therefore, by modifying or propagating a
covered work, you indicate your acceptance of this License to do so.
10. Automatic Licensing of Downstream Recipients.
Each time you convey a covered work, the recipient automatically
receives a license from the original licensors, to run, modify and
propagate that work, subject to this License. You are not responsible
for enforcing compliance by third parties with this License.
An "entity transaction" is a transaction transferring control of an
organization, or substantially all assets of one, or subdividing an
organization, or merging organizations. If propagation of a covered
work results from an entity transaction, each party to that
transaction who receives a copy of the work also receives whatever
licenses to the work the party's predecessor in interest had or could
give under the previous paragraph, plus a right to possession of the
Corresponding Source of the work from the predecessor in interest, if
the predecessor has it or can get it with reasonable efforts.
You may not impose any further restrictions on the exercise of the
rights granted or affirmed under this License. For example, you may
not impose a license fee, royalty, or other charge for exercise of
rights granted under this License, and you may not initiate litigation
(including a cross-claim or counterclaim in a lawsuit) alleging that
any patent claim is infringed by making, using, selling, offering for
sale, or importing the Program or any portion of it.
11. Patents.
A "contributor" is a copyright holder who authorizes use under this
License of the Program or a work on which the Program is based. The
work thus licensed is called the contributor's "contributor version".
A contributor's "essential patent claims" are all patent claims
owned or controlled by the contributor, whether already acquired or
hereafter acquired, that would be infringed by some manner, permitted
by this License, of making, using, or selling its contributor version,
but do not include claims that would be infringed only as a
consequence of further modification of the contributor version. For
purposes of this definition, "control" includes the right to grant
patent sublicenses in a manner consistent with the requirements of
this License.
Each contributor grants you a non-exclusive, worldwide, royalty-free
patent license under the contributor's essential patent claims, to
make, use, sell, offer for sale, import and otherwise run, modify and
propagate the contents of its contributor version.
In the following three paragraphs, a "patent license" is any express
agreement or commitment, however denominated, not to enforce a patent
(such as an express permission to practice a patent or covenant not to
sue for patent infringement). To "grant" such a patent license to a
party means to make such an agreement or commitment not to enforce a
patent against the party.
If you convey a covered work, knowingly relying on a patent license,
and the Corresponding Source of the work is not available for anyone
to copy, free of charge and under the terms of this License, through a
publicly available network server or other readily accessible means,
then you must either (1) cause the Corresponding Source to be so
available, or (2) arrange to deprive yourself of the benefit of the
patent license for this particular work, or (3) arrange, in a manner
consistent with the requirements of this License, to extend the patent
license to downstream recipients. "Knowingly relying" means you have
actual knowledge that, but for the patent license, your conveying the
covered work in a country, or your recipient's use of the covered work
in a country, would infringe one or more identifiable patents in that
country that you have reason to believe are valid.
If, pursuant to or in connection with a single transaction or
arrangement, you convey, or propagate by procuring conveyance of, a
covered work, and grant a patent license to some of the parties
receiving the covered work authorizing them to use, propagate, modify
or convey a specific copy of the covered work, then the patent license
you grant is automatically extended to all recipients of the covered
work and works based on it.
A patent license is "discriminatory" if it does not include within
the scope of its coverage, prohibits the exercise of, or is
conditioned on the non-exercise of one or more of the rights that are
specifically granted under this License. You may not convey a covered
work if you are a party to an arrangement with a third party that is
in the business of distributing software, under which you make payment
to the third party based on the extent of your activity of conveying
the work, and under which the third party grants, to any of the
parties who would receive the covered work from you, a discriminatory
patent license (a) in connection with copies of the covered work
conveyed by you (or copies made from those copies), or (b) primarily
for and in connection with specific products or compilations that
contain the covered work, unless you entered into that arrangement,
or that patent license was granted, prior to 28 March 2007.
Nothing in this License shall be construed as excluding or limiting
any implied license or other defenses to infringement that may
otherwise be available to you under applicable patent law.
12. No Surrender of Others' Freedom.
If conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot convey a
covered work so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you may
not convey it at all. For example, if you agree to terms that obligate you
to collect a royalty for further conveying from those to whom you convey
the Program, the only way you could satisfy both those terms and this
License would be to refrain entirely from conveying the Program.
13. Use with the GNU Affero General Public License.
Notwithstanding any other provision of this License, you have
permission to link or combine any covered work with a work licensed
under version 3 of the GNU Affero General Public License into a single
combined work, and to convey the resulting work. The terms of this
License will continue to apply to the part which is the covered work,
but the special requirements of the GNU Affero General Public License,
section 13, concerning interaction through a network will apply to the
combination as such.
14. Revised Versions of this License.
The Free Software Foundation may publish revised and/or new versions of
the GNU General Public License from time to time. Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.
Each version is given a distinguishing version number. If the
Program specifies that a certain numbered version of the GNU General
Public License "or any later version" applies to it, you have the
option of following the terms and conditions either of that numbered
version or of any later version published by the Free Software
Foundation. If the Program does not specify a version number of the
GNU General Public License, you may choose any version ever published
by the Free Software Foundation.
If the Program specifies that a proxy can decide which future
versions of the GNU General Public License can be used, that proxy's
public statement of acceptance of a version permanently authorizes you
to choose that version for the Program.
Later license versions may give you additional or different
permissions. However, no additional obligations are imposed on any
author or copyright holder as a result of your choosing to follow a
later version.
15. Disclaimer of Warranty.
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
16. Limitation of Liability.
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
SUCH DAMAGES.
17. Interpretation of Sections 15 and 16.
If the disclaimer of warranty and limitation of liability provided
above cannot be given local legal effect according to their terms,
reviewing courts shall apply local law that most closely approximates
an absolute waiver of all civil liability in connection with the
Program, unless a warranty or assumption of liability accompanies a
copy of the Program in return for a fee.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.
To do so, attach the following notices to the program. It is safest
to attach them to the start of each source file to most effectively
state the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.
<one line to give the program's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <https://www.gnu.org/licenses/>.
Also add information on how to contact you by electronic and paper mail.
If the program does terminal interaction, make it output a short
notice like this when it starts in an interactive mode:
<program> Copyright (C) <year> <name of author>
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
This is free software, and you are welcome to redistribute it
under certain conditions; type `show c' for details.
The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License. Of course, your program's commands
might be different; for a GUI interface, you would use an "about box".
You should also get your employer (if you work as a programmer) or school,
if any, to sign a "copyright disclaimer" for the program, if necessary.
For more information on this, and how to apply and follow the GNU GPL, see
<https://www.gnu.org/licenses/>.
The GNU General Public License does not permit incorporating your program
into proprietary programs. If your program is a subroutine library, you
may consider it more useful to permit linking proprietary applications with
the library. If this is what you want to do, use the GNU Lesser General
Public License instead of this License. But first, please read
<https://www.gnu.org/licenses/why-not-lgpl.html>.
================================================
FILE: PackagingProject/Package.appxmanifest
================================================
<?xml version="1.0" encoding="utf-8"?>
<Package
xmlns="http://schemas.microsoft.com/appx/manifest/foundation/windows10"
xmlns:uap="http://schemas.microsoft.com/appx/manifest/uap/windows10"
xmlns:rescap="http://schemas.microsoft.com/appx/manifest/foundation/windows10/restrictedcapabilities"
xmlns:desktop="http://schemas.microsoft.com/appx/manifest/desktop/windows10"
IgnorableNamespaces="uap rescap">
<Identity
Name="14082CryzenTechnologies.RoundedTB"
Publisher="CN=26093D81-5B64-4610-8EFB-00B295E6FE81"
Version="1.3.1.0" />
<Properties>
<DisplayName>RoundedTB</DisplayName>
<PublisherDisplayName>TorchGM</PublisherDisplayName>
<Logo>Images\StoreLogo.png</Logo>
</Properties>
<Dependencies>
<TargetDeviceFamily Name="Windows.Universal" MinVersion="10.0.0.0" MaxVersionTested="10.0.0.0" />
<TargetDeviceFamily Name="Windows.Desktop" MinVersion="10.0.14393.0" MaxVersionTested="10.0.14393.0" />
</Dependencies>
<Resources>
<Resource Language="x-generate"/>
</Resources>
<Applications>
<Application Id="App"
Executable="RoundedTB.exe"
EntryPoint="$targetentrypoint$">
<uap:VisualElements
DisplayName="RoundedTB"
Description="Adds rounded corners, margins and segments to your taskbar!"
BackgroundColor="transparent"
Square150x150Logo="Images\Square150x150Logo.png"
Square44x44Logo="Images\Square44x44Logo.png">
<uap:DefaultTile Wide310x150Logo="Images\Wide310x150Logo.png" Square71x71Logo="Images\SmallTile.png" Square310x310Logo="Images\LargeTile.png" ShortName="RoundedTB">
<uap:ShowNameOnTiles>
<uap:ShowOn Tile="square150x150Logo"/>
<uap:ShowOn Tile="square310x310Logo"/>
<uap:ShowOn Tile="wide310x150Logo"/>
</uap:ShowNameOnTiles>
</uap:DefaultTile >
<uap:SplashScreen Image="Images\SplashScreen.png" />
</uap:VisualElements>
<Extensions>
<desktop:Extension Category="windows.startupTask" Executable="RoundedTB\RoundedTB.exe" EntryPoint="Windows.FullTrustApplication">
<desktop:StartupTask TaskId="RTB" Enabled="true" DisplayName="RoundedTB" />
</desktop:Extension>
</Extensions>
</Application>
</Applications>
<Capabilities>
<Capability Name="internetClient" />
<rescap:Capability Name="runFullTrust" />
</Capabilities>
</Package>
================================================
FILE: PackagingProject/RoundedTB.Package.wapproj
================================================
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup Condition="'$(VisualStudioVersion)' == '' or '$(VisualStudioVersion)' < '15.0'">
<VisualStudioVersion>15.0</VisualStudioVersion>
</PropertyGroup>
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|x86">
<Configuration>Debug</Configuration>
<Platform>x86</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|x86">
<Configuration>Release</Configuration>
<Platform>x86</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|x64">
<Configuration>Debug</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|x64">
<Configuration>Release</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|ARM">
<Configuration>Debug</Configuration>
<Platform>ARM</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|ARM">
<Configuration>Release</Configuration>
<Platform>ARM</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|ARM64">
<Configuration>Debug</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|ARM64">
<Configuration>Release</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|AnyCPU">
<Configuration>Debug</Configuration>
<Platform>AnyCPU</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|AnyCPU">
<Configuration>Release</Configuration>
<Platform>AnyCPU</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Remote Debug|AnyCPU">
<Configuration>Remote Debug</Configuration>
<Platform>AnyCPU</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Remote Debug|ARM">
<Configuration>Remote Debug</Configuration>
<Platform>ARM</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Remote Debug|ARM64">
<Configuration>Remote Debug</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Remote Debug|x64">
<Configuration>Remote Debug</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Remote Debug|x86">
<Configuration>Remote Debug</Configuration>
<Platform>x86</Platform>
</ProjectConfiguration>
</ItemGroup>
<PropertyGroup>
<WapProjPath Condition="'$(WapProjPath)'==''">$(MSBuildExtensionsPath)\Microsoft\DesktopBridge\</WapProjPath>
</PropertyGroup>
<Import Project="$(WapProjPath)\Microsoft.DesktopBridge.props" />
<PropertyGroup>
<ProjectGuid>660827eb-23be-4bd2-8a5b-355134f264d8</ProjectGuid>
<TargetPlatformVersion>10.0.19041.0</TargetPlatformVersion>
<TargetPlatformMinVersion>10.0.17763.0</TargetPlatformMinVersion>
<DefaultLanguage>en-US</DefaultLanguage>
<AppxPackageSigningEnabled>True</AppxPackageSigningEnabled>
<GenerateAppInstallerFile>False</GenerateAppInstallerFile>
<PackageCertificateThumbprint>949AB122C53DAF37D8272CA0AA2350D81DDE2329</PackageCertificateThumbprint>
<AppxPackageSigningTimestampDigestAlgorithm>SHA256</AppxPackageSigningTimestampDigestAlgorithm>
<AppxAutoIncrementPackageRevision>False</AppxAutoIncrementPackageRevision>
<GenerateTestArtifacts>True</GenerateTestArtifacts>
<AppxBundlePlatforms>neutral</AppxBundlePlatforms>
<HoursBetweenUpdateChecks>0</HoursBetweenUpdateChecks>
<EntryPointProjectUniqueName>..\RoundedTB\RoundedTB.csproj</EntryPointProjectUniqueName>
<AppxSymbolPackageEnabled>True</AppxSymbolPackageEnabled>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
<AppxBundle>Always</AppxBundle>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<AppxBundle>Always</AppxBundle>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM'">
<AppxBundle>Always</AppxBundle>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Remote Debug|ARM'">
<AppxBundle>Always</AppxBundle>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x86'">
<AppxBundle>Always</AppxBundle>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<AppxBundle>Always</AppxBundle>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Remote Debug|x64'">
<AppxBundle>Always</AppxBundle>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM'">
<AppxBundle>Always</AppxBundle>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<AppxBundle>Always</AppxBundle>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x86'">
<AppxBundle>Always</AppxBundle>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Remote Debug|x86'">
<AppxBundle>Always</AppxBundle>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<AppxBundle>Always</AppxBundle>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Remote Debug|AnyCPU'">
<AppxBundle>Always</AppxBundle>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
<AppxBundle>Always</AppxBundle>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Remote Debug|ARM64'">
<AppxBundle>Always</AppxBundle>
</PropertyGroup>
<ItemGroup>
<AppxManifest Include="Package.appxmanifest">
<SubType>Designer</SubType>
</AppxManifest>
</ItemGroup>
<ItemGroup>
<Content Include="Images\LargeTile.scale-100.png" />
<Content Include="Images\LargeTile.scale-125.png" />
<Content Include="Images\LargeTile.scale-150.png" />
<Content Include="Images\LargeTile.scale-200.png" />
<Content Include="Images\LargeTile.scale-400.png" />
<Content Include="Images\SmallTile.scale-100.png" />
<Content Include="Images\SmallTile.scale-125.png" />
<Content Include="Images\SmallTile.scale-150.png" />
<Content Include="Images\SmallTile.scale-200.png" />
<Content Include="Images\SmallTile.scale-400.png" />
<Content Include="Images\SplashScreen.scale-100.png" />
<Content Include="Images\SplashScreen.scale-125.png" />
<Content Include="Images\SplashScreen.scale-150.png" />
<Content Include="Images\SplashScreen.scale-200.png" />
<Content Include="Images\SplashScreen.scale-400.png" />
<Content Include="Images\Square150x150Logo.scale-100.png" />
<Content Include="Images\Square150x150Logo.scale-125.png" />
<Content Include="Images\Square150x150Logo.scale-150.png" />
<Content Include="Images\Square150x150Logo.scale-200.png" />
<Content Include="Images\Square150x150Logo.scale-400.png" />
<Content Include="Images\Square44x44Logo.altform-lightunplated_targetsize-16.png" />
<Content Include="Images\Square44x44Logo.altform-lightunplated_targetsize-24.png" />
<Content Include="Images\Square44x44Logo.altform-lightunplated_targetsize-256.png" />
<Content Include="Images\Square44x44Logo.altform-lightunplated_targetsize-32.png" />
<Content Include="Images\Square44x44Logo.altform-lightunplated_targetsize-48.png" />
<Content Include="Images\Square44x44Logo.altform-unplated_targetsize-16.png" />
<Content Include="Images\Square44x44Logo.altform-unplated_targetsize-256.png" />
<Content Include="Images\Square44x44Logo.altform-unplated_targetsize-32.png" />
<Content Include="Images\Square44x44Logo.altform-unplated_targetsize-48.png" />
<Content Include="Images\Square44x44Logo.scale-100.png" />
<Content Include="Images\Square44x44Logo.scale-125.png" />
<Content Include="Images\Square44x44Logo.scale-150.png" />
<Content Include="Images\Square44x44Logo.scale-200.png" />
<Content Include="Images\Square44x44Logo.scale-400.png" />
<Content Include="Images\Square44x44Logo.targetsize-16.png" />
<Content Include="Images\Square44x44Logo.targetsize-24.png" />
<Content Include="Images\Square44x44Logo.targetsize-24_altform-unplated.png" />
<Content Include="Images\Square44x44Logo.targetsize-256.png" />
<Content Include="Images\Square44x44Logo.targetsize-32.png" />
<Content Include="Images\Square44x44Logo.targetsize-48.png" />
<Content Include="Images\StoreLogo.scale-100.png" />
<Content Include="Images\StoreLogo.scale-125.png" />
<Content Include="Images\StoreLogo.scale-150.png" />
<Content Include="Images\StoreLogo.scale-200.png" />
<Content Include="Images\StoreLogo.scale-400.png" />
<Content Include="Images\Wide310x150Logo.scale-100.png" />
<Content Include="Images\Wide310x150Logo.scale-125.png" />
<Content Include="Images\Wide310x150Logo.scale-150.png" />
<Content Include="Images\Wide310x150Logo.scale-200.png" />
<Content Include="Images\Wide310x150Logo.scale-400.png" />
<None Include="Package.StoreAssociation.xml" />
</ItemGroup>
<Import Project="$(WapProjPath)\Microsoft.DesktopBridge.targets" />
<ItemGroup>
<PackageReference Include="Microsoft.Windows.SDK.BuildTools" Version="10.0.19041.8" PrivateAssets="all" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\RoundedTB\RoundedTB.csproj" />
</ItemGroup>
</Project>
================================================
FILE: README.md
================================================

# RoundedTB
#### Add margins, rounded corners and segments to your taskbars!

## How do I get it?
You can download the latest version from the [release page](https://github.com/Gniang/RoundedTB/releases).
The Microsoft Store's RoundedTB is not mine. It's the [original version](https://github.com/RoundedTB/RoundedTB).
## Known issues
- Auto-hiding compatibillity. (Widnows taskbar setting)
- not working.
- Windows 10.
- Windows 10 has not been verified. Probably will no longer be supported.
- TranslucentTB compatibility.
- Rounded corners are not antialiased.
- Due to a Windows limitation. ([#4](https://github.com/torchgm/RoundedTB/issues/4))
- Dynamic mode won't hide the left side of the taskbar if fisrst started(the taskbar alignment has never been changed).
- This can be worked around by changing the alignment to Left and back to Center. ([#98](https://github.com/torchgm/RoundedTB/issues/98))
- When using dynamic mode, the taskbar may occasionally become too large, too small or not update.
- This can usually be fixed by moving a window to or from that monitor or briefly changing the taskbar alignment.
- Dynamic mode may not be released when RoundedTB is exited.
- Restarting RoundedTB doesn't help, try restarting the PC.
- The top of the taskbar is not rounded.
- Set the top margin to a larger value (30-50?) , you can adjust the appearance in that session. But it may be a different value when restarted the Windows.
## Other info
RoundedTB was created by torchgm. thanks.
https://github.com/RoundedTB/RoundedTB
torchgm says "RoundedTB is just a hobby of mine, and I'm certainly not an expert in this field, so I'm really sorry if you encounter a bug!".
me too.
If anything breaks catastrophically, press <kbd>Ctrl</kbd>+<kbd>Shift</kbd>+<kbd>Esc</kbd> to open Task Manager, end RoundedTB and then restart Explorer. At worst, just reboot your PC. RoundedTB makes no permanent changes (though it will run on startup if you enable it from the tray icon), so restarting should clear any issues.
================================================
FILE: RoundedTB/.editorconfig
================================================
# Rules in this file were initially inferred by Visual Studio IntelliCode from the C:\Users\Torch\source\repos\RoundedTB\RoundedTB\ codebase based on best match to current usage at 30/01/2022 A.D.
# You can modify the rules from these initially generated values to suit your own policies
# You can learn more about editorconfig here: https://docs.microsoft.com/en-us/visualstudio/ide/editorconfig-code-style-settings-reference
[*.cs]
#Core editorconfig formatting - indentation
#use soft tabs (spaces) for indentation
indent_style = space
#Formatting - indentation options
#indent switch case contents.
csharp_indent_case_contents = true
#indent switch labels
csharp_indent_switch_labels = true
#Formatting - new line options
#place catch statements on a new line
csharp_new_line_before_catch = true
#place else statements on a new line
csharp_new_line_before_else = true
#require finally statements to be on a new line after the closing brace
csharp_new_line_before_finally = true
#require members of object intializers to be on separate lines
csharp_new_line_before_members_in_object_initializers = true
#require braces to be on a new line for object_collection_array_initializers, control_blocks, properties, lambdas, types, accessors, and methods (also known as "Allman" style)
csharp_new_line_before_open_brace = object_collection_array_initializers, control_blocks, properties, lambdas, types, accessors, methods
#Formatting - organize using options
#sort System.* using directives alphabetically, and place them before other usings
dotnet_sort_system_directives_first = true
#Formatting - spacing options
#require NO space between a cast and the value
csharp_space_after_cast = false
#require a space before the colon for bases or interfaces in a type declaration
csharp_space_after_colon_in_inheritance_clause = true
#require a space after a keyword in a control flow statement such as a for loop
csharp_space_after_keywords_in_control_flow_statements = true
#require a space before the colon for bases or interfaces in a type declaration
csharp_space_before_colon_in_inheritance_clause = true
#remove space within empty argument list parentheses
csharp_space_between_method_call_empty_parameter_list_parentheses = false
#remove space between method call name and opening parenthesis
csharp_space_between_method_call_name_and_opening_parenthesis = false
#do not place space characters after the opening parenthesis and before the closing parenthesis of a method call
csharp_space_between_method_call_parameter_list_parentheses = false
#remove space within empty parameter list parentheses for a method declaration
csharp_space_between_method_declaration_empty_parameter_list_parentheses = false
#place a space character after the opening parenthesis and before the closing parenthesis of a method declaration parameter list.
csharp_space_between_method_declaration_parameter_list_parentheses = false
#Formatting - wrapping options
#leave code block on single line
csharp_preserve_single_line_blocks = true
#Style - Code block preferences
#prefer curly braces even for one line of code
csharp_prefer_braces = true:suggestion
#Style - expression bodied member options
#prefer block bodies for accessors
csharp_style_expression_bodied_accessors = false:suggestion
#prefer block bodies for constructors
csharp_style_expression_bodied_constructors = false:suggestion
#prefer block bodies for methods
csharp_style_expression_bodied_methods = false:suggestion
#prefer block bodies for properties
csharp_style_expression_bodied_properties = false:suggestion
#Style - expression level options
#prefer out variables to be declared before the method call
csharp_style_inlined_variable_declaration = false:suggestion
#Style - Expression-level preferences
#prefer objects to not be initialized using object initializers
dotnet_style_object_initializer = false:suggestion
#Style - implicit and explicit types
#prefer explicit type over var in all cases, unless overridden by another code style rule
csharp_style_var_elsewhere = false:suggestion
#prefer explicit type over var to declare variables with built-in system types such as int
csharp_style_var_for_built_in_types = false:suggestion
#prefer explicit type over var when the type is already mentioned on the right-hand side of a declaration
csharp_style_var_when_type_is_apparent = false:suggestion
#Style - language keyword and framework type options
#prefer the language keyword for local variables, method parameters, and class members, instead of the type name, for types that have a keyword to represent them
dotnet_style_predefined_type_for_locals_parameters_members = true:suggestion
#Style - modifier options
#prefer accessibility modifiers to be declared except for public interface members. This will currently not differ from always and will act as future proofing for if C# adds default interface methods.
dotnet_style_require_accessibility_modifiers = for_non_interface_members:suggestion
#Style - Modifier preferences
#when this rule is set to a list of modifiers, prefer the specified ordering.
csharp_preferred_modifier_order = public,private,static,extern,sealed:suggestion
#Style - Pattern matching
#prefer pattern matching instead of is expression with type casts
csharp_style_pattern_matching_over_as_with_null_check = true:suggestion
#Style - qualification options
#prefer fields not to be prefaced with this. or Me. in Visual Basic
dotnet_style_qualification_for_field = false:suggestion
#prefer methods not to be prefaced with this. or Me. in Visual Basic
dotnet_style_qualification_for_method = false:suggestion
#prefer properties not to be prefaced with this. or Me. in Visual Basic
dotnet_style_qualification_for_property = false:suggestion
[*.{cs,vb}]
dotnet_diagnostic.CA1416.severity=silent
================================================
FILE: RoundedTB/AboutWindow.xaml
================================================
<Window x:Class="RoundedTB.AboutWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:RoundedTB"
xmlns:wpfui="clr-namespace:WPFUI.Controls;assembly=WPFUI"
mc:Ignorable="d"
Style="{StaticResource UiWindow}"
Background="#20808080"
Title="RoundedTB - About" Height="616" Width="500"
Visibility ="Visible" ResizeMode="NoResize" Opacity="1.001">
<Grid>
<Image x:Name="bannerMst" Visibility ="Hidden" HorizontalAlignment="Center" Height="128" VerticalAlignment="Top" Opacity="0.8" Source="res\HeadBanner.png" Width="500" Stretch="UniformToFill" Margin="0,-16,0,0"/>
<Image x:Name="bannerDev" Visibility ="Hidden" HorizontalAlignment="Center" Height="128" VerticalAlignment="Top" Opacity="0.8" Source="res\HeadBannerDev.png" Width="500" Stretch="UniformToFill" Margin="0,-16,0,0"/>
<Image x:Name="bannerCan" Visibility ="Visible" HorizontalAlignment="Center" Height="146" VerticalAlignment="Top" Opacity="0.8" Source="res\HeadBannerCan.png" Width="500" Stretch="UniformToFill" Margin="0,-16,0,0"/>
<Button x:Name="okButton" Content="OK" Margin="0,0,10,10" VerticalAlignment="Bottom" HorizontalAlignment="Right" Width="85" Click="okButton_Click" FontWeight="Normal"/>
<TextBlock x:Name="titleBlock" HorizontalAlignment="Left" Margin="10,35,0,0" TextWrapping="Wrap" Text="Welcome to RoundedTB!" VerticalAlignment="Top" FontWeight="Normal" FontFamily="Segoe UI Semibold" FontSize="36" Opacity="0.795"/>
<TextBlock x:Name="subtitleBlock" HorizontalAlignment="Left" Margin="10,85,0,0" TextWrapping="Wrap" Text="Canary" VerticalAlignment="Top" FontWeight="Normal" FontFamily="Segoe UI Semibold" FontSize="22" Opacity="0.795" Height="30"/>
<wpfui:TitleBar x:Name="aboutTitleBar" Grid.Row="0" NotifyIconTooltip="RoundedTB" ApplicationNavigation="True" Title="RoundedTB - About" Icon="pack://application:,,,/RoundedTBCanary.ico" Height="51" ShowMaximize="False"/>
<TextBlock x:Name="bodyBlockMain" Margin="10,134,10,0" TextWrapping="Wrap" FontWeight="Normal" FontFamily="Segoe UI SemiBold" FontSize="14" Height="37" VerticalAlignment="Top">
<Bold>Thanks for downloading RoundedTB. Expand the following categories for more information.</Bold>
</TextBlock>
<ScrollViewer Margin="0,176,0,0" VerticalScrollBarVisibility="Hidden" Height="378" VerticalAlignment="Top">
<StackPanel Width="473">
<Expander x:Name="expander0" HorizontalAlignment="Center" Header="What's new" VerticalAlignment="Top" Width="480" FontSize="16" FontFamily="Segoe UI Semibold">
<Grid>
<TextBlock Margin="0,5,0,0" x:Name="bodyBlock0" TextWrapping="Wrap" FontWeight="Normal" FontFamily="Segoe UI" FontSize="14" Opacity="0.8" LineHeight="23">
• Nobody knows. Some say secrets lie amongst these builds. And bugs. Honestly, I'm pretty sure they're 90% bug. 95%. 98%. Actually the fact you're even seeing this text is probably a bug. idk tbh, i give up
<LineBreak/>
<Bold>REMINDER: Autohide is currently rather buggy and must be entirely disabled in Windows.</Bold>
<LineBreak/>
</TextBlock>
</Grid>
</Expander>
<Expander x:Name="expander1" HorizontalAlignment="Center" Header="About basic options" VerticalAlignment="Top" Width="480" FontSize="16" FontFamily="Segoe UI Semibold">
<Grid>
<TextBlock Margin="0,5,0,0" x:Name="bodyBlock1" TextWrapping="Wrap" FontWeight="Normal" FontFamily="Segoe UI" FontSize="14" Opacity="0.8" LineHeight="23">
<Bold>• Margin</Bold> - makes the taskbar slimmer on all sides by this many logical pixels.
<LineBreak/>
<Bold>• Corner radius</Bold> - controls the radius of the taskbar's rounded corners.
<LineBreak/>
<Bold>• Advanced</Bold> - toggles a menu of advanced and experimental features.
<LineBreak/>
<Bold>• Apply</Bold> - applies and saves any unset changes.
<LineBreak/>
</TextBlock>
</Grid>
</Expander>
<Expander x:Name="expander2" HorizontalAlignment="Center" Header="About advanced options" VerticalAlignment="Top" Width="480" FontSize="16" FontFamily="Segoe UI Semibold">
<Grid>
<TextBlock Margin="0,5,0,0" x:Name="bodyBlock2" TextWrapping="Wrap" FontWeight="Normal" FontFamily="Segoe UI" FontSize="14" Opacity="0.8" LineHeight="23">
<Bold>• [...] Margins</Bold> - individually sets the margin for each side of the taskbar.
<LineBreak/>
<Bold>• Dynamic mode (Windows 11)</Bold> - Dynamically adjusts the size of the taskbar depending on how many apps are open.
<LineBreak/>
<Bold>• Split mode (Windows 10)</Bold> - allows you to resize the taskbar. Like dynamic mode, but manually adjustable; some setup is required, enable for more info.
<LineBreak/>
<Bold>• Show system tray</Bold> - Displays the system tray in dynamic/split mode. This option can be toggled at any time by pressing <Bold>Win+F2</Bold>.
<LineBreak/>
<Bold>• Show system tray on hover</Bold> - Displays the system tray in dynamic/split mode when the mouse hovers over it. This overrides the above option.
<LineBreak/>
<Bold>• TranslucentTB compatibility</Bold> - enables compatibility with TranslucentTB. For more info, enable this option.
<LineBreak/>
<Bold>• Fill taskbar when maximised</Bold> - Fills the taskbar when a window is maximised on that taskbar's monitor.
<LineBreak/>
<Bold>• Fill taskbar on alt+tab (Windows 11)</Bold> - Fills taskbars when alt+tab or the Task Switcher is invoked.
<LineBreak/>
</TextBlock>
</Grid>
</Expander>
<Expander x:Name="expander3" HorizontalAlignment="Center" Header="Known issues" VerticalAlignment="Top" Width="480" FontSize="16" FontFamily="Segoe UI Semibold">
<Grid>
<TextBlock Margin="0,5,0,0" x:Name="bodyBlock3" TextWrapping="Wrap" FontWeight="Normal" FontFamily="Segoe UI" FontSize="14" Opacity="0.8" LineHeight="23">
• Using RoundedTB with Windows' autohide feature can result in heavy flickering, bugs, an inability to access the taskbar and isn't supported. An upcoming version of RoundedTB will introduce a custom autohide feature that will work correctly.
<LineBreak/>
• Dynamic mode and split mode only work correctly when the taskbar is at the top or bottom of the monitor.
<LineBreak/>
• Split mode on Windows 10 is currently only supported on the primary monitor.
<LineBreak/>
• Taskbar mods other than TranslucentTB are not yet officially supported. Let me know if you run into compatibility issues with other taskbar mods/tweaks.
<LineBreak/>
• When using dynamic mode, the taskbar may occasionally become too large, too small or not update. This can usually be fixed by moving a window to or from that monitor or briefly changing the taskbar alignment. These issues will be reduced in upcoming updates.
<LineBreak/>
</TextBlock>
</Grid>
</Expander>
<Expander x:Name="expander4" HorizontalAlignment="Center" Header="Help and information" VerticalAlignment="Top" Width="480" FontSize="16" FontFamily="Segoe UI Semibold">
<Grid>
<TextBlock Margin="0,5,0,0" x:Name="bodyBlock4" TextWrapping="Wrap" FontWeight="Normal" FontFamily="Segoe UI" FontSize="14" Opacity="0.8" LineHeight="21">
• More in-depth instructions, tips and tricks are available in the
<Hyperlink NavigateUri="https://github.com/torchgm/RoundedTB#readme" RequestNavigate="Hyperlink_RequestNavigate">
README
</Hyperlink>.
<LineBreak/>
• If you're having any issues, or just want to talk about RoundedTB, feel free to join
<Hyperlink NavigateUri="https://discord.gg/wYQJd8VGSB" RequestNavigate="Hyperlink_RequestNavigate">
the official Discord server
</Hyperlink>.
<LineBreak/>
• If you want to browse the source code, file an issue or suggest a feature, check out
<Hyperlink NavigateUri="https://github.com/torchgm/RoundedTB" RequestNavigate="Hyperlink_RequestNavigate">
the RoundedTB GitHub repository
</Hyperlink>.
<LineBreak/>
<LineBreak/>
RoundedTB is licensed under the
<Hyperlink NavigateUri="https://github.com/torchgm/RoundedTB/blob/master/LICENSE" RequestNavigate="Hyperlink_RequestNavigate">
GNU General Public License v3.0
</Hyperlink>. By using the software, you agree to accepting the terms of this license.
<LineBreak/>
</TextBlock>
</Grid>
</Expander>
<Expander x:Name="expander5" HorizontalAlignment="Center" Header="Debug" VerticalAlignment="Top" Width="480" FontSize="16" FontFamily="Segoe UI Semibold">
<StackPanel>
<Button x:Name="configButton" Content="Open config file" Margin="0,10,0,0" Click="configButton_Click"/>
<Button x:Name="logButton" Content="Open log file" Margin="0,10,0,0" Click="logButton_Click"/>
</StackPanel>
</Expander>
</StackPanel>
</ScrollViewer>
</Grid>
</Window>
================================================
FILE: RoundedTB/AboutWindow.xaml.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Shapes;
using System.Windows.Navigation;
using System.Diagnostics;
namespace RoundedTB
{
/// <summary>
/// Interaction logic for AboutWindow.xaml
/// </summary>
public partial class AboutWindow : Window
{
public AboutWindow()
{
InitializeComponent();
WPFUI.Background.Manager.Apply(WPFUI.Background.BackgroundType.Mica, this);
}
private void okButton_Click(object sender, RoutedEventArgs e)
{
Close();
}
private void Hyperlink_RequestNavigate(object sender, RequestNavigateEventArgs e)
{
Process.Start(e.Uri.ToString());
}
private void configButton_Click(object sender, RoutedEventArgs e)
{
Process.Start(((MainWindow)Application.Current.MainWindow).configPath);
}
private void logButton_Click(object sender, RoutedEventArgs e)
{
Process.Start(((MainWindow)Application.Current.MainWindow).logPath);
}
}
}
================================================
FILE: RoundedTB/App.config
================================================
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.8"/>
</startup>
</configuration>
================================================
FILE: RoundedTB/App.xaml
================================================
<Application x:Class="RoundedTB.App"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:RoundedTB"
StartupUri="MainWindow.xaml">
<Application.Resources>
<ResourceDictionary>
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="pack://application:,,,/WPFUI;component/Styles/Theme/Dark.xaml" />
<ResourceDictionary Source="pack://application:,,,/WPFUI;component/Styles/WPFUI.xaml" />
</ResourceDictionary.MergedDictionaries>
</ResourceDictionary>
</Application.Resources>
</Application>
================================================
FILE: RoundedTB/App.xaml.cs
================================================
using System;
using System.Collections.Generic;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Threading.Tasks;
using System.Windows;
namespace RoundedTB
{
/// <summary>
/// Interaction logic for App.xaml
/// </summary>
public partial class App : Application
{
protected override void OnStartup(StartupEventArgs e)
{
WPFUI.Theme.Watcher.Start();
}
}
}
================================================
FILE: RoundedTB/AppBars.cs
================================================
using System;
using System.Runtime.InteropServices;
namespace RoundedTB
{
class AppBars
{
[DllImport("shell32.dll")]
public static extern IntPtr SHAppBarMessage(UInt32 dwMessage, ref APPBARDATA pData);
public enum AppBarMessages
{
New = 0x00,
Remove = 0x01,
QueryPos = 0x02,
SetPos = 0x03,
GetState = 0x04,
GetTaskBarPos = 0x05,
Activate = 0x06,
GetAutoHideBar = 0x07,
SetAutoHideBar = 0x08,
WindowPosChanged = 0x09,
SetState = 0x0a
}
[StructLayout(LayoutKind.Sequential)]
public struct APPBARDATA
{
public UInt32 cbSize;
public IntPtr hWnd;
public UInt32 uCallbackMessage;
public UInt32 uEdge;
public LocalPInvoke.RECT rc;
public Int32 lParam;
}
public enum AppBarStates
{
AutoHide = 0x01,
AlwaysOnTop = 0x02
}
/// <summary>
/// Set the Taskbar State option
/// </summary>
/// <param name="option">AppBarState to activate</param>
public static void SetAppbarState(IntPtr hwnd, AppBarStates option)
{
APPBARDATA msgData = new APPBARDATA();
msgData.cbSize = (UInt32)Marshal.SizeOf(msgData);
msgData.hWnd = hwnd;
msgData.lParam = (Int32)(option);
SHAppBarMessage((UInt32)AppBarMessages.SetState, ref msgData);
}
/// <summary>
/// Gets the current Taskbar state
/// </summary>
/// <returns>current Taskbar state</returns>
public static AppBarStates GetAppbarState(IntPtr hwnd)
{
APPBARDATA msgData = new APPBARDATA();
msgData.cbSize = (UInt32)Marshal.SizeOf(msgData);
msgData.hWnd = hwnd;
return (AppBarStates)SHAppBarMessage((UInt32)AppBarMessages.GetState, ref msgData);
}
/// <summary>
/// Unregisters the taskbar as an appbar
/// </summary>
public static void MakeAppbarSad(IntPtr hwnd)
{
APPBARDATA msgData = new APPBARDATA();
msgData.cbSize = (UInt32)Marshal.SizeOf(msgData);
msgData.hWnd = hwnd;
SHAppBarMessage((UInt32)AppBarMessages.Remove, ref msgData);
}
/// <summary>
/// Unregisters the taskbar as an appbar
/// </summary>
public static void SetAppbarRect(IntPtr hwnd, LocalPInvoke.RECT rc)
{
APPBARDATA msgData = new APPBARDATA();
msgData.cbSize = (UInt32)Marshal.SizeOf(msgData);
msgData.hWnd = hwnd;
msgData.rc = rc;
msgData.uEdge = 0x3;
SHAppBarMessage((UInt32)AppBarMessages.SetPos, ref msgData);
}
}
}
================================================
FILE: RoundedTB/Background.cs
================================================
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Diagnostics;
using System.Text;
using System.Windows;
using System.Windows.Threading;
namespace RoundedTB
{
public class Background
{
private struct ReloadChecker
{
public bool IsReload { get; set; }
}
// Just have a reference point for the Dispatcher
public MainWindow mw;
bool redrawOverride = false;
int infrequentCount = 0;
public Background()
{
mw = (MainWindow)Application.Current.MainWindow;
}
// Main method for the BackgroundWorker - runs indefinitely
public void DoWork(object sender, DoWorkEventArgs e)
{
mw.interaction.AddLog("in bw");
BackgroundWorker worker = sender as BackgroundWorker;
while (true)
{
try
{
if (worker.CancellationPending == true)
{
mw.interaction.AddLog("cancelling");
e.Cancel = true;
break;
}
// Primary loop for the running process
else
{
// Section for running less important things without requiring an additional thread
infrequentCount++;
if (infrequentCount == 10)
{
// Check to see if settings need to be shown
List<IntPtr> windowList = Interaction.GetTopLevelWindows();
foreach (IntPtr hwnd in windowList)
{
StringBuilder windowClass = new StringBuilder(1024);
StringBuilder windowTitle = new StringBuilder(1024);
try
{
LocalPInvoke.GetClassName(hwnd, windowClass, 1024);
LocalPInvoke.GetWindowText(hwnd, windowTitle, 1024);
if (windowClass.ToString().Contains("HwndWrapper[RoundedTB.exe") && windowTitle.ToString() == "RoundedTB_SettingsRequest")
{
mw.Dispatcher.Invoke(() =>
{
if (mw.Visibility != Visibility.Visible)
{
mw.ShowMenuItem_Click(null, null);
}
});
LocalPInvoke.SetWindowText(hwnd, "RoundedTB");
}
}
catch (Exception) { }
}
ReloadChecker checker = new();
mw.taskbarDetails?.ForEach(taskbar =>
{
if (taskbar.AppListXaml.ReloadRequired)
{
taskbar.AppListXaml.ReloadTaskbarFrameElement();
checker.IsReload = true;
}
});
// Update tray icon
mw.interaction.RefreshUiTray(isForceReset: checker.IsReload);
infrequentCount = 0;
}
// Check if the taskbar is centred, and if it is, directly update the settings; using an interim bool to avoid delaying because I'm lazy
bool isCentred = Taskbar.CheckIfCentred();
mw.activeSettings.IsCentred = isCentred;
// Work with static values to avoid some null reference exceptions
List<Types.Taskbar> taskbars = mw.taskbarDetails;
Types.Settings settings = mw.activeSettings;
// If the number of taskbars has changed, regenerate taskbar information
if (Taskbar.TaskbarCountOrHandleChanged(taskbars.Count, taskbars[0].TaskbarHwnd))
{
// Forcefully reset taskbars if the taskbar count or main taskbar handle has changed
taskbars.ForEach(t => t.Dispose());
taskbars = Taskbar.GenerateTaskbarInfo(mw.interaction.IsWindows11());
mw.interaction.RefreshUiTray(isForceReset: true);
Debug.WriteLine("Regenerating taskbar info");
}
for (int current = 0; current < taskbars.Count; current++)
{
if (taskbars[current].TaskbarHwnd == IntPtr.Zero || taskbars[current].AppListHwnd == IntPtr.Zero)
{
taskbars.ForEach(t => t.Dispose());
taskbars = Taskbar.GenerateTaskbarInfo(mw.interaction.IsWindows11());
mw.interaction.RefreshUiTray(isForceReset: true);
Debug.WriteLine("Regenerating taskbar info due to a missing handle");
break;
}
// Get the latest quick details of this taskbar
Types.Taskbar newTaskbar = Taskbar.GetQuickTaskbarRects(taskbars[current].TaskbarHwnd, taskbars[current].TrayHwnd, taskbars[current].AppListHwnd, taskbars[current].AppListXaml);
// If the taskbar's monitor has a maximised window, reset it so it's "filled"
if (Taskbar.TaskbarShouldBeFilled(taskbars[current].TaskbarHwnd, settings))
{
if (taskbars[current].Ignored == false)
{
Taskbar.ResetTaskbar(taskbars[current], settings);
taskbars[current].Ignored = true;
}
continue;
}
// Showhide tray on hover
if (settings.ShowSegmentsOnHover)
{
LocalPInvoke.RECT currentTrayRect = taskbars[current].TrayRect;
LocalPInvoke.RECT currentWidgetsRect = taskbars[current].TaskbarRect;
currentWidgetsRect.Right = Convert.ToInt32(currentWidgetsRect.Right - (currentWidgetsRect.Right - currentWidgetsRect.Left) + (168 * taskbars[current].ScaleFactor));
if (currentTrayRect.Left != 0)
{
LocalPInvoke.GetCursorPos(out LocalPInvoke.POINT msPt);
bool isHoveringOverTray = LocalPInvoke.PtInRect(ref currentTrayRect, msPt);
bool isHoveringOverWidgets = LocalPInvoke.PtInRect(ref currentWidgetsRect, msPt);
if (isHoveringOverTray && !settings.ShowTray)
{
settings.ShowTray = true;
taskbars[current].Ignored = true;
}
else if (!isHoveringOverTray)
{
taskbars[current].Ignored = true;
settings.ShowTray = false;
}
if (isHoveringOverWidgets && !settings.ShowWidgets)
{
settings.ShowWidgets = true;
taskbars[current].Ignored = true;
}
else if (!isHoveringOverWidgets)
{
taskbars[current].Ignored = true;
settings.ShowWidgets = false;
}
}
}
if (settings.AutoHide > 0)
{
LocalPInvoke.RECT currentTaskbarRect = taskbars[current].TaskbarRect;
LocalPInvoke.GetCursorPos(out LocalPInvoke.POINT msPt);
bool isHoveringOverTaskbar;
if (taskbars[current].TaskbarHidden)
{
currentTaskbarRect.Top = currentTaskbarRect.Bottom - 2;
isHoveringOverTaskbar = LocalPInvoke.PtInRect(ref currentTaskbarRect, msPt);
}
else
{
isHoveringOverTaskbar = LocalPInvoke.PtInRect(ref currentTaskbarRect, msPt);
}
if (isHoveringOverTaskbar)
{
Debug.WriteLine("___");
}
int animSpeed = 15;
byte taskbarOpacity = 0;
LocalPInvoke.GetLayeredWindowAttributes(taskbars[current].TaskbarHwnd, out _, out taskbarOpacity, out _);
//Debug.WriteLine($"Taskbar opacity: {taskbarOpacity}");
if (isHoveringOverTaskbar && taskbarOpacity == 1)
{
int style = LocalPInvoke.GetWindowLong(taskbars[current].TaskbarHwnd, LocalPInvoke.GWL_EXSTYLE).ToInt32();
if ((style & LocalPInvoke.WS_EX_TRANSPARENT) == LocalPInvoke.WS_EX_TRANSPARENT)
{
LocalPInvoke.SetWindowLong(taskbars[current].TaskbarHwnd, LocalPInvoke.GWL_EXSTYLE, LocalPInvoke.GetWindowLong(taskbars[current].TaskbarHwnd, LocalPInvoke.GWL_EXSTYLE).ToInt32() ^ LocalPInvoke.WS_EX_TRANSPARENT);
}
LocalPInvoke.SetLayeredWindowAttributes(taskbars[current].TaskbarHwnd, 0, 63, LocalPInvoke.LWA_ALPHA);
System.Threading.Thread.Sleep(animSpeed);
LocalPInvoke.SetLayeredWindowAttributes(taskbars[current].TaskbarHwnd, 0, 127, LocalPInvoke.LWA_ALPHA);
System.Threading.Thread.Sleep(animSpeed);
LocalPInvoke.SetLayeredWindowAttributes(taskbars[current].TaskbarHwnd, 0, 191, LocalPInvoke.LWA_ALPHA);
System.Threading.Thread.Sleep(animSpeed);
LocalPInvoke.SetLayeredWindowAttributes(taskbars[current].TaskbarHwnd, 0, 255, LocalPInvoke.LWA_ALPHA);
taskbars[current].Ignored = true;
taskbars[current].TaskbarHidden = false;
Debug.WriteLine("MouseOver TB");
}
else if (!isHoveringOverTaskbar && taskbarOpacity == 255)
{
LocalPInvoke.SetLayeredWindowAttributes(taskbars[current].TaskbarHwnd, 0, 191, LocalPInvoke.LWA_ALPHA);
System.Threading.Thread.Sleep(animSpeed);
LocalPInvoke.SetLayeredWindowAttributes(taskbars[current].TaskbarHwnd, 0, 127, LocalPInvoke.LWA_ALPHA);
System.Threading.Thread.Sleep(animSpeed);
LocalPInvoke.SetLayeredWindowAttributes(taskbars[current].TaskbarHwnd, 0, 63, LocalPInvoke.LWA_ALPHA);
System.Threading.Thread.Sleep(animSpeed);
LocalPInvoke.SetLayeredWindowAttributes(taskbars[current].TaskbarHwnd, 0, 1, LocalPInvoke.LWA_ALPHA);
int style = LocalPInvoke.GetWindowLong(taskbars[current].TaskbarHwnd, LocalPInvoke.GWL_EXSTYLE).ToInt32();
if ((style & LocalPInvoke.WS_EX_TRANSPARENT) != LocalPInvoke.WS_EX_TRANSPARENT)
{
LocalPInvoke.SetWindowLong(taskbars[current].TaskbarHwnd, LocalPInvoke.GWL_EXSTYLE, LocalPInvoke.GetWindowLong(taskbars[current].TaskbarHwnd, LocalPInvoke.GWL_EXSTYLE).ToInt32() ^ LocalPInvoke.WS_EX_TRANSPARENT);
}
taskbars[current].Ignored = true;
taskbars[current].TaskbarHidden = true;
Debug.WriteLine("MouseOff TB");
}
}
else
{
int animSpeed = 15;
byte taskbarOpacity = 0;
LocalPInvoke.GetLayeredWindowAttributes(taskbars[current].TaskbarHwnd, out _, out taskbarOpacity, out _);
if (taskbarOpacity < 255)
{
int style = LocalPInvoke.GetWindowLong(taskbars[current].TaskbarHwnd, LocalPInvoke.GWL_EXSTYLE).ToInt32();
if ((style & LocalPInvoke.WS_EX_TRANSPARENT) == LocalPInvoke.WS_EX_TRANSPARENT)
{
LocalPInvoke.SetWindowLong(taskbars[current].TaskbarHwnd, LocalPInvoke.GWL_EXSTYLE, LocalPInvoke.GetWindowLong(taskbars[current].TaskbarHwnd, LocalPInvoke.GWL_EXSTYLE).ToInt32() ^ LocalPInvoke.WS_EX_TRANSPARENT);
}
LocalPInvoke.SetLayeredWindowAttributes(taskbars[current].TaskbarHwnd, 0, 63, LocalPInvoke.LWA_ALPHA);
System.Threading.Thread.Sleep(animSpeed);
LocalPInvoke.SetLayeredWindowAttributes(taskbars[current].TaskbarHwnd, 0, 127, LocalPInvoke.LWA_ALPHA);
System.Threading.Thread.Sleep(animSpeed);
LocalPInvoke.SetLayeredWindowAttributes(taskbars[current].TaskbarHwnd, 0, 191, LocalPInvoke.LWA_ALPHA);
System.Threading.Thread.Sleep(animSpeed);
LocalPInvoke.SetLayeredWindowAttributes(taskbars[current].TaskbarHwnd, 0, 255, LocalPInvoke.LWA_ALPHA);
taskbars[current].Ignored = true;
taskbars[current].TaskbarHidden = false;
}
}
// If the taskbar's overall rect has changed, update it. If it's simple, just update. If it's dynamic, check it's a valid change, then update it.
if (Taskbar.TaskbarRefreshRequired(taskbars[current], newTaskbar, settings.IsDynamic) || taskbars[current].Ignored || redrawOverride)
{
Debug.WriteLine($"Refresh required on taskbar {current}");
taskbars[current].Ignored = false;
int isFullTest = newTaskbar.TrayRect.Left - newTaskbar.AppListRect.Right;
mw.interaction.AddLog($"Taskbar: {current} - AppList ends: {newTaskbar.AppListRect.Right} - Tray starts: {newTaskbar.TrayRect.Left} - Total gap: {isFullTest}");
if (!settings.IsDynamic || (isFullTest <= taskbars[current].ScaleFactor * 25 && isFullTest > 0 && newTaskbar.TrayRect.Left != 0))
{
// Add the rect changes to the temporary list of taskbars
taskbars[current].TaskbarRect = newTaskbar.TaskbarRect;
taskbars[current].AppListRect = newTaskbar.AppListRect;
taskbars[current].TrayRect = newTaskbar.TrayRect;
Taskbar.UpdateSimpleTaskbar(taskbars[current], settings);
mw.interaction.AddLog($"Updated taskbar {current} simply");
}
else
{
if (Taskbar.CheckDynamicUpdateIsValid(taskbars[current], newTaskbar))
{
// Add the rect changes to the temporary list of taskbars
taskbars[current].TaskbarRect = newTaskbar.TaskbarRect;
taskbars[current].AppListRect = newTaskbar.AppListRect;
taskbars[current].TrayRect = newTaskbar.TrayRect;
Taskbar.UpdateDynamicTaskbar(taskbars[current], settings);
mw.interaction.AddLog($"Updated taskbar {current} dynamically");
}
}
}
}
mw.taskbarDetails = taskbars;
System.Threading.Thread.Sleep(100);
}
}
catch (TypeInitializationException ex)
{
mw.interaction.AddLog(ex.Message);
mw.interaction.AddLog(ex.InnerException.Message);
throw ex;
}
}
}
}
}
================================================
FILE: RoundedTB/EnumerableExtensions.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace RoundedTB
{
public static class EnumerableExtensions
{
public static void ForEach<T>(this IEnumerable<T> src, Action<T> action)
{
foreach (var item in src)
{
action(item);
}
}
}
}
================================================
FILE: RoundedTB/FodyWeavers.xml
================================================
<Weavers xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="FodyWeavers.xsd">
<Costura />
</Weavers>
================================================
FILE: RoundedTB/IAppVisibility.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.InteropServices;
using System.Text;
using System.Threading.Tasks;
namespace RoundedTB
{
public enum MONITOR_APP_VISIBILITY
{
MAV_UNKNOWN = 0,
MAV_NO_APP_VISIBLE = 1,
MAV_APP_VISIBLE = 2
}
[ComImport, Guid("6584CE6B-7D82-49C2-89C9-C6BC02BA8C38"), InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
public interface IAppVisibilityEvents
{
void AppVisibilityOnMonitorChanged(IntPtr hMonitor, MONITOR_APP_VISIBILITY previousMode, MONITOR_APP_VISIBILITY currentMode);
void LauncherVisibilityChange([MarshalAs(UnmanagedType.Bool)] bool currentVisibleState);
}
[ComImport, Guid("2246EA2D-CAEA-4444-A3C4-6DE827E44313"), InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
public interface IAppVisibility
{
MONITOR_APP_VISIBILITY GetAppVisibilityOnMonitor(IntPtr hMonitor);
[return: MarshalAs(UnmanagedType.Bool)]
bool IsLauncherVisible();
uint Advise(IAppVisibilityEvents pCallback);
void Unadvise(uint dwCookie);
}
[ComImport, Guid("7E5FE3D9-985F-4908-91F9-EE19F9FD1514"), ClassInterface(ClassInterfaceType.None)]
public class AppVisibility { }
}
================================================
FILE: RoundedTB/Infobox.xaml
================================================
<Window x:Class="RoundedTB.Infobox"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:RoundedTB"
mc:Ignorable="d"
Title="Infobox" Height="430" Width="500"
xmlns:ui="http://schemas.modernwpf.com/2019"
Visibility ="Visible" ResizeMode="NoResize" Opacity="1.001">
<Grid>
<Button x:Name="okButton" Content="OK" Margin="0,0,10,10" VerticalAlignment="Bottom" HorizontalAlignment="Right" Width="37" Click="okButton_Click"/>
<TextBlock x:Name="titleBlock" HorizontalAlignment="Left" Margin="10,10,0,0" TextWrapping="Wrap" Text="InformationTitle" VerticalAlignment="Top" FontWeight="Normal" FontFamily="Segoe UI Semibold" FontSize="14"/>
<TextBlock x:Name="bodyBlock" Margin="10,34,10,47" TextWrapping="Wrap" Text="Body of information that's quite interesting. Honestly I'm not sure how you found this as it should never appear in normal use. Are you peeking through the source? I really wouldn't recommend that tbh" FontWeight="Normal" FontFamily="Segoe UI" FontSize="14"/>
</Grid>
</Window>
================================================
FILE: RoundedTB/Infobox.xaml.cs
================================================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Shapes;
namespace RoundedTB
{
/// <summary>
/// Interaction logic for Infobox.xaml
/// </summary>
public partial class Infobox : Window
{
public Infobox()
{
InitializeComponent();
}
private void okButton_Click(object sender, RoutedEventArgs e)
{
Close();
}
}
}
================================================
FILE: RoundedTB/Interaction.cs
================================================
using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.IO;
using System.Windows;
using System.Threading;
using System.Drawing;
using System.Runtime.InteropServices;
namespace RoundedTB
{
public class Interaction
{
public MainWindow mw;
string m = "";
public Interaction()
{
try
{
mw = (MainWindow)Application.Current.MainWindow;
}
catch (Exception)
{
// No idea why this was necessary but it was so it's here now. Yay. TODO - work out why this is suddenly broken and unbreak it
}
}
public Types.Settings ReadJSON()
{
string jsonSettings = File.ReadAllText(mw.configPath);
Types.Settings settings = JsonConvert.DeserializeObject<Types.Settings>(jsonSettings);
// compatible old settings
if (settings.DynamicSecondaryClockLayout == null)
{
settings.DynamicSecondaryClockLayout = new Types.SegmentSettings { CornerRadius = 7, MarginLeft = 3, MarginTop = 3, MarginRight = 3, MarginBottom = 3 };
}
return settings;
}
public bool IsWindows11()
{
Debug.WriteLine(Environment.OSVersion.Version.Build);
if (Environment.OSVersion.Version.Build >= 21996)
{
return true;
}
return false;
}
public void WriteJSON()
{
File.Create(mw.configPath).Close();
File.WriteAllText(mw.configPath, JsonConvert.SerializeObject(mw.activeSettings, Formatting.Indented));
}
public void FileSystem()
{
File.Create(mw.logPath).Close();
if (!File.Exists(mw.configPath))
{
if (mw.isWindows11)
{
mw.activeSettings = new Types.Settings()
{
SimpleTaskbarLayout = new Types.SegmentSettings { CornerRadius = 7, MarginLeft = 3, MarginTop = 3, MarginRight = 3, MarginBottom = 3 },
DynamicAppListLayout = new Types.SegmentSettings { CornerRadius = 7, MarginLeft = 3, MarginTop = 3, MarginRight = 3, MarginBottom = 3 },
DynamicTrayLayout = new Types.SegmentSettings { CornerRadius = 7, MarginLeft = 3, MarginTop = 3, MarginRight = 3, MarginBottom = 3 },
DynamicWidgetsLayout = new Types.SegmentSettings { CornerRadius = 7, MarginLeft = 3, MarginTop = 3, MarginRight = 3, MarginBottom = 3 },
DynamicSecondaryClockLayout = new Types.SegmentSettings { CornerRadius = 7, MarginLeft = 3, MarginTop = 3, MarginRight = 3, MarginBottom = 3 },
WidgetsWidth = 168,
ClockWidth = 110,
IsDynamic = false,
IsCentred = false,
IsWindows11 = true,
ShowTray = false,
CompositionCompat = false,
IsNotFirstLaunch = false,
FillOnMaximise = true,
FillOnTaskSwitch = true,
ShowSegmentsOnHover = false,
AutoHide = 0
};
}
else
{
mw.activeSettings = new Types.Settings()
{
SimpleTaskbarLayout = new Types.SegmentSettings { CornerRadius = 16, MarginLeft = 2, MarginTop = 2, MarginRight = 2, MarginBottom = 2 },
DynamicAppListLayout = new Types.SegmentSettings { CornerRadius = 16, MarginLeft = 2, MarginTop = 2, MarginRight = 2, MarginBottom = 2 },
DynamicTrayLayout = new Types.SegmentSettings { CornerRadius = 16, MarginLeft = 2, MarginTop = 2, MarginRight = 2, MarginBottom = 2 },
DynamicWidgetsLayout = new Types.SegmentSettings { CornerRadius = 16, MarginLeft = 2, MarginTop = 2, MarginRight = 2, MarginBottom = 2 },
DynamicSecondaryClockLayout = new Types.SegmentSettings { CornerRadius = 16, MarginLeft = 2, MarginTop = 2, MarginRight = 2, MarginBottom = 2 },
WidgetsWidth = 168,
ClockWidth = 110,
IsDynamic = false,
IsCentred = false,
IsWindows11 = false,
ShowTray = false,
CompositionCompat = false,
IsNotFirstLaunch = false,
FillOnMaximise = true,
FillOnTaskSwitch = false,
ShowSegmentsOnHover = false,
AutoHide = 0
};
}
WriteJSON(); // butts - Missy Quarry, 2020
}
if (File.ReadAllText(mw.configPath) == "" || File.ReadAllText(mw.configPath) == null)
{
WriteJSON(); // Initialises empty file
}
}
public static bool SetWorkspace(LocalPInvoke.RECT rect)
{
bool result = LocalPInvoke.SystemParametersInfo(LocalPInvoke.SPI_SETWORKAREA, 0, ref rect, LocalPInvoke.SPIF_change);
if (!result)
{
// Get error
Debug.WriteLine("Error setting work area: " + Marshal.GetLastWin32Error().ToString());
}
return result;
}
public void AddLog(string message)
{
//m = $"[{DateTime.Now}] {message}\n";
//File.AppendAllText(mw.logPath, m);
}
public static bool IsTranslucentTBRunning()
{
Mutex mutex = null;
try
{
return Mutex.TryOpenExisting("344635E9-9AE4-4E60-B128-D53E25AB70A7", out mutex);
}
finally
{
mutex?.Dispose();
}
}
// Request that TranslucentTB forefully refesh the taskbar
public static IntPtr UpdateTranslucentTB(IntPtr taskbarHwnd)
{
return LocalPInvoke.SendMessage(LocalPInvoke.FindWindow("TTB_WorkerWindow", "TTB_WorkerWindow"), LocalPInvoke.RegisterWindowMessage("TTB_ForceRefreshTaskbar"), 0, taskbarHwnd);
}
// Attempt to forcefully refresh the taskbar
public static void UpdateLegacyTB(IntPtr taskbarHwnd)
{
const int WM_DWMCOMPOSITIONCHANGED = 789;
LocalPInvoke.SendMessage(taskbarHwnd, WM_DWMCOMPOSITIONCHANGED, 1, IntPtr.Zero);
}
/// <summary>
/// Calculates whether or not an integer is odd or even.
/// </summary>
/// <param name="input">
/// The integer to be checked for oddness.
/// </param>
/// <returns>
/// A nullable bool, which represents if the provided integer is odd. If the provided integer is neither even nor odd, then returns null.
/// </returns>
public bool? IsOdd(int input)
{
// The following section declares and initialises the required variables for the caculation.
decimal comparison = input / 2; // A decimal, representing approximately half of the user's input.
int check = Convert.ToInt32(comparison) * 2; // An integer-representation of the user's input value.
// The following section tests for oddness by looking for differences in the prior-initialised values.
if (check == input) // Checks if the "check" value is equal to the input.
{
return false; // Return false to indicate the value is not odd.
}
else if (check != input) // Repeat the above check in the event that quantum tunnelling has resulted in a variable changing.
{
return true; // Return true to indicate the value is odd.
}
return null; // Finally, return null to indicate that the provided number is neither odd nor even - not currently required, added for future-proofing in the event the concept of mathematics changes significantly enough to warrant it.
// (this is a joke to annoy sylly)
}
public IntPtr HwndHook(IntPtr hwnd, int msg, IntPtr wParam, IntPtr lParam, ref bool handled)
{
const int WM_HOTKEY = 0x0312;
switch (msg)
{
case WM_HOTKEY:
Debug.WriteLine(msg);
switch (wParam.ToInt32())
{
case 9000:
int vkey = ((int)lParam >> 16) & 0xFFFF;
Debug.WriteLine(vkey);
if (vkey == 0x71)
{
if (mw.showTrayCheckBox.IsChecked == true)
{
mw.showTrayCheckBox.IsChecked = false;
}
else
{
mw.showTrayCheckBox.IsChecked = true;
}
mw.ApplyButton_Click(null, null);
}
handled = true;
break;
}
break;
}
return IntPtr.Zero;
}
public static bool IsAutoHideEnabled()
{
return Math.Abs(SystemParameters.PrimaryScreenHeight - SystemParameters.WorkArea.Height) > 0;
}
public bool IsTaskbarVisibleOnMonitor(LocalPInvoke.RECT tbRectP, LocalPInvoke.RECT monitorRectP)
{
Rectangle tbRect = new Rectangle(tbRectP.Left + 3, tbRectP.Top + 3, tbRectP.Right - tbRectP.Left - 3, tbRectP.Bottom - tbRectP.Top - 3);
Rectangle monitorRect = new Rectangle(monitorRectP.Left, monitorRectP.Top, monitorRectP.Right - monitorRectP.Left, monitorRectP.Bottom - monitorRectP.Top);
return tbRect.IntersectsWith(monitorRect);
}
public delegate bool CallBack(int hwnd, int lParam);
public delegate bool EnumWindowsProc(IntPtr hwnd, IntPtr lParam);
public static List<IntPtr> GetTopLevelWindows()
{
List<IntPtr> AllActiveHandles = new List<IntPtr>();
GCHandle listHandle = GCHandle.Alloc(AllActiveHandles);
try
{
EnumWindowsProc tlProc = new EnumWindowsProc(EnumWindow);
LocalPInvoke.EnumWindows(tlProc, GCHandle.ToIntPtr(listHandle));
}
finally
{
if (listHandle.IsAllocated)
{
listHandle.Free();
}
}
return AllActiveHandles;
}
private static bool EnumWindow(IntPtr handle, IntPtr pointer)
{
GCHandle gch = GCHandle.FromIntPtr(pointer);
if (!(gch.Target is List<IntPtr> list))
{
throw new InvalidCastException("GCHandle Target could not be cast as List<IntPtr>");
}
list.Add(handle);
return true;
}
public static bool TaskbarOnMonitorWithMaximisedWindow(IntPtr taskbarHwnd)
{
return true;
}
public void RefreshUiTray(bool isForceReset)
{
// When the taskbar changes, there may be not show tray icons. so need for a redraw.
mw.Dispatcher.Invoke(() =>
{
try
{
mw.TrayIconCheck(isForceReset);
}
catch (Exception)
{
// TODO: write log
// GUI refresh, gracefully handle errors.
}
});
}
public enum TaskbarPosition
{
Unknown = -1,
Left,
Top,
Right,
Bottom,
}
public sealed class Taskbar
{
public Rectangle Bounds
{
get;
private set;
}
public TaskbarPosition Position
{
get;
private set;
}
public System.Drawing.Point Location
{
get
{
return Bounds.Location;
}
}
public System.Drawing.Size Size
{
get
{
return Bounds.Size;
}
}
//Always returns false under Windows 7
public bool AlwaysOnTop
{
get;
private set;
}
public bool AutoHide
{
get;
private set;
}
public Taskbar(IntPtr taskbarHandle)
{
LocalPInvoke.APPBARDATA data = new LocalPInvoke.APPBARDATA();
data.cbSize = (uint)Marshal.SizeOf(typeof(LocalPInvoke.APPBARDATA));
data.hWnd = taskbarHandle;
IntPtr result = LocalPInvoke.SHAppBarMessage(LocalPInvoke.ABM.GetTaskbarPos, ref data);
Position = (TaskbarPosition)data.uEdge;
Bounds = Rectangle.FromLTRB(data.rc.Left, data.rc.Top, data.rc.Right, data.rc.Bottom);
data.cbSize = (uint)Marshal.SizeOf(typeof(LocalPInvoke.APPBARDATA));
result = LocalPInvoke.SHAppBarMessage(LocalPInvoke.ABM.GetState, ref data);
int state = result.ToInt32();
AlwaysOnTop = (state & LocalPInvoke.ABS.AlwaysOnTop) == LocalPInvoke.ABS.AlwaysOnTop;
AutoHide = (state & LocalPInvoke.ABS.Autohide) == LocalPInvoke.ABS.Autohide;
}
}
}
}
================================================
FILE: RoundedTB/LocalPInvoke.cs
================================================
using System;
using System.Diagnostics;
using System.Runtime.InteropServices;
using System.Text;
namespace RoundedTB
{
public class LocalPInvoke
{
[DllImport("user32.dll", SetLastError = true)]
public static extern bool SetWindowPos(IntPtr hWnd, IntPtr hWndInsertAfter, int X, int Y, int cx, int cy, SetWindowPosFlags uFlags);
[DllImport("user32.dll")]
public static extern bool RegisterHotKey(IntPtr hWnd, int id, int fsModifiers, int vk);
[DllImport("user32.dll")]
public static extern bool UnregisterHotKey(IntPtr hWnd, int id);
[DllImport("user32.dll")]
public static extern bool ShowWindow(IntPtr hWnd, int nCmdShow);
[DllImport("user32.dll")]
public static extern bool RedrawWindow(IntPtr hWnd, IntPtr lprcUpdate, IntPtr hrgnUpdate, RedrawWindowFlags flags);
[DllImport("user32.dll", CharSet = CharSet.Auto)]
public static extern IntPtr SendMessage(IntPtr hWnd, int Msg, int wParam, IntPtr lParam);
[DllImport("user32.dll")]
public static extern bool PtInRect(ref RECT lprc, POINT pt);
[DllImport("user32.dll")]
[return: MarshalAs(UnmanagedType.Bool)]
public static extern bool IsWindow(IntPtr hWnd);
[DllImport("user32.dll")]
public static extern int GetWindowRgn(IntPtr hWnd, out IntPtr hRgn);
[DllImport("user32.dll")]
public static extern int SetWindowRgn(IntPtr hWnd, IntPtr hRgn, bool bRedraw);
[DllImport("gdi32.dll")]
public static extern IntPtr CreateRoundRectRgn(int x1, int y1, int x2, int y2, int w, int h);
[DllImport("gdi32.dll")]
public static extern IntPtr CreateRectRgn(int x1, int y1, int x2, int y2);
[DllImport("user32.dll")]
public static extern IntPtr FindWindowExA(IntPtr hWndParent, IntPtr hWndChildAfter, string lpszClass, string lpszWindow);
[DllImport("user32.dll")]
public static extern int GetDpiForWindow(IntPtr hwnd);
[DllImport("user32.dll")]
public static extern bool GetWindowRect(IntPtr hWnd, out RECT lpRect);
[DllImport("user32.dll")]
public static extern IntPtr MonitorFromWindow(IntPtr hwnd, uint dwFlags);
[DllImport("user32.dll")]
public static extern bool MoveWindow(IntPtr hWnd, int X, int Y, int nWidth, int nHeight, bool bRepaint);
[DllImport("user32.dll")]
[return: MarshalAs(UnmanagedType.Bool)]
public static extern bool GetWindowRect(HandleRef hWnd, out RECT lpRect);
[DllImport("gdi32.dll")]
public static extern int CombineRgn(IntPtr hrgnDest, IntPtr hrgnSrc1, IntPtr hrgnSrc2, int fnCombineMode);
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Auto)]
public static extern int RegisterWindowMessage(string lpString);
[DllImport("shell32.dll", SetLastError = true)]
public static extern IntPtr SHAppBarMessage(ABM dwMessage, [In] ref APPBARDATA pData);
[DllImport("user32.dll", SetLastError = true)]
public static extern IntPtr FindWindow(string lpClassName, string lpWindowName);
[DllImport("user32.dll", SetLastError = true)]
[return: MarshalAs(UnmanagedType.Bool)]
public static extern bool GetCursorPos(out POINT lpPoint);
[DllImport("user32.dll")]
public static extern int ShowWindow(int hwnd, int command);
[DllImport("user32.dll", CharSet = CharSet.Auto, SetLastError = true)]
[return: MarshalAs(UnmanagedType.Bool)]
public static extern bool SystemParametersInfo(int uiAction, int uiParam, ref RECT pvParam, int fWinIni);
[DllImport("user32.dll")]
[return: MarshalAs(UnmanagedType.Bool)]
public static extern bool IsWindowVisible(IntPtr hWnd);
[DllImport("dwmapi.dll")]
public static extern int DwmGetWindowAttribute(IntPtr hwnd, DWMWINDOWATTRIBUTE dwAttribute, out bool pvAttribute, int cbAttribute);
[DllImport("user32.dll")]
[return: MarshalAs(UnmanagedType.Bool)]
public static extern bool EnumWindows(Interaction.EnumWindowsProc lpEnumFunc, IntPtr lParam);
[DllImport("user32.dll", SetLastError = true)]
[return: MarshalAs(UnmanagedType.Bool)]
public static extern bool GetWindowPlacement(IntPtr hWnd, ref WINDOWPLACEMENT lpwndpl);
[DllImport("user32.dll", SetLastError = true, EntryPoint = "GetClassNameW", CharSet = CharSet.Unicode)]
public static extern int GetClassName(IntPtr hWnd, StringBuilder lpClassName, int nMaxCount);
[DllImport("user32.dll")]
public static extern IntPtr WindowFromPoint(POINT p);
[DllImport("user32.dll", CharSet = CharSet.Auto, SetLastError = true)]
public static extern int GetWindowText(IntPtr hWnd, StringBuilder lpString, int nMaxCount);
[DllImport("user32.dll")]
public static extern bool SetForegroundWindow(IntPtr hWnd);
[DllImport("user32.dll")]
public static extern bool ShowWindowAsync(IntPtr hWnd, int nCmdShow);
[DllImport("user32.dll")]
public static extern bool IsIconic(IntPtr hWnd);
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Auto)]
public static extern bool SetWindowText(IntPtr hwnd, string lpString);
[DllImport("shell32.dll")]
public static extern IntPtr SHAppBarMessage(uint dwMessage, [In] ref APPBARDATA pData);
[DllImport("user32.dll")]
public static extern bool SetLayeredWindowAttributes(IntPtr hwnd, uint crKey, byte bAlpha, uint dwFlags);
[DllImport("user32.dll")]
public static extern int SetWindowLong(IntPtr hWnd, int nIndex, int dwNewLong);
[DllImport("user32.dll")]
public static extern IntPtr GetWindowLong(IntPtr hWnd, int nIndex);
[DllImport("user32.dll", SetLastError = true)]
public static extern bool GetLayeredWindowAttributes(IntPtr hwnd, out uint crKey, out byte bAlpha, out uint dwFlags);
[DllImport("gdi32.dll")]
public static extern bool DeleteObject(IntPtr hObject);
public const int GWL_EXSTYLE = -20;
public const int WS_EX_LAYERED = 0x80000;
public const int WS_EX_TRANSPARENT = 0x00000020;
public const int LWA_ALPHA = 0x2;
public const int LWA_COLORKEY = 0x1;
public enum AppBarStates
{
AutoHide = 0x01,
AlwaysOnTop = 0x02
}
public enum DWMWINDOWATTRIBUTE : uint
{
NCRenderingEnabled = 1,
NCRenderingPolicy,
TransitionsForceDisabled,
AllowNCPaint,
CaptionButtonBounds,
NonClientRtlLayout,
ForceIconicRepresentation,
Flip3DPolicy,
ExtendedFrameBounds,
HasIconicBitmap,
DisallowPeek,
ExcludedFromPeek,
Cloak,
Cloaked,
FreezeRepresentation
}
public enum ShowState : int
{
SW_HIDE = 0,
SW_SHOWNORMAL = 1,
SW_NORMAL = 1,
SW_SHOWMINIMIZED = 2,
SW_SHOWMAXIMIZED = 3,
SW_MAXIMIZE = 3,
SW_SHOWNOACTIVATE = 4,
SW_SHOW = 5,
SW_MINIMIZE = 6,
SW_SHOWMINNOACTIVE = 7,
SW_SHOWNA = 8,
SW_RESTORE = 9,
SW_SHOWDEFAULT = 10,
SW_FORCEMINIMIZE = 11,
SW_MAX = 11
}
public const int SPIF_SENDWININICHANGE = 2;
public const int SPIF_UPDATEINIFILE = 1;
public const int SPIF_change = SPIF_UPDATEINIFILE | SPIF_SENDWININICHANGE;
public const int SPI_SETWORKAREA = 47;
public const int SPI_GETWORKAREA = 48;
public const int SW_HIDE = 0;
public const int SW_SHOW = 1;
public const int SW_SHOWNORMAL = 1;
public const int SW_SHOWMINIMIZED = 2;
public const int SW_SHOWMAXIMIZED = 3;
public const int SW_SHOWNOACTIVATE = 4;
public const int SW_RESTORE = 9;
public const int SW_SHOWDEFAULT = 10;
public struct POINT
{
public int x;
public int y;
}
[StructLayout(LayoutKind.Sequential)]
public struct RECT
{
public int Left;
public int Top;
public int Right;
public int Bottom;
}
[StructLayout(LayoutKind.Sequential)]
public struct APPBARDATA
{
public uint cbSize;
public IntPtr hWnd;
public uint uCallbackMessage;
public ABE uEdge;
public RECT rc;
public int lParam;
}
public enum ABM : uint
{
New = 0x00000000,
Remove = 0x00000001,
QueryPos = 0x00000002,
SetPos = 0x00000003,
GetState = 0x00000004,
GetTaskbarPos = 0x00000005,
Activate = 0x00000006,
GetAutoHideBar = 0x00000007,
SetAutoHideBar = 0x00000008,
WindowPosChanged = 0x00000009,
SetState = 0x0000000A,
}
public enum ABE : uint
{
Left = 0,
Top = 1,
Right = 2,
Bottom = 3
}
public static class ABS
{
public const int Autohide = 0x0000001;
public const int AlwaysOnTop = 0x0000002;
}
/// <summary>
/// Contains information about the placement of a window on the screen.
/// </summary>
[Serializable]
[StructLayout(LayoutKind.Sequential)]
public struct WINDOWPLACEMENT
{
/// <summary>
/// The length of the structure, in bytes. Before calling the GetWindowPlacement or SetWindowPlacement functions, set this member to sizeof(WINDOWPLACEMENT).
/// <para>
/// GetWindowPlacement and SetWindowPlacement fail if this member is not set correctly.
/// </para>
/// </summary>
public int Length;
/// <summary>
/// Specifies flags that control the position of the minimized window and the method by which the window is restored.
/// </summary>
public int Flags;
/// <summary>
/// The current show state of the window.
/// </summary>
public ShowWindowCommands ShowCmd;
/// <summary>
/// The coordinates of the window's upper-left corner when the window is minimized.
/// </summary>
public POINT MinPosition;
/// <summary>
/// The coordinates of the window's upper-left corner when the window is maximized.
/// </summary>
public POINT MaxPosition;
/// <summary>
/// The window's coordinates when the window is in the restored position.
/// </summary>
public RECT NormalPosition;
/// <summary>
/// Gets the default (empty) value.
/// </summary>
public static WINDOWPLACEMENT Default
{
get
{
WINDOWPLACEMENT result = new WINDOWPLACEMENT();
result.Length = Marshal.SizeOf(result);
return result;
}
}
}
public enum ShowWindowCommands
{
/// <summary>
/// Hides the window and activates another window.
/// </summary>
Hide = 0,
/// <summary>
/// Activates and displays a window. If the window is minimized or
/// maximized, the system restores it to its original size and position.
/// An application should specify this flag when displaying the window
/// for the first time.
/// </summary>
Normal = 1,
/// <summary>
/// Activates the window and displays it as a minimized window.
/// </summary>
ShowMinimized = 2,
/// <summary>
/// Maximizes the specified window.
/// </summary>
Maximize = 3, // is this the right value?
/// <summary>
/// Activates the window and displays it as a maximized window.
/// </summary>
ShowMaximized = 3,
/// <summary>
/// Displays a window in its most recent size and position. This value
/// is similar to <see cref="Win32.ShowWindowCommand.Normal"/>, except
/// the window is not activated.
/// </summary>
ShowNoActivate = 4,
/// <summary>
/// Activates the window and displays it in its current size and position.
/// </summary>
Show = 5,
/// <summary>
/// Minimizes the specified window and activates the next top-level
/// window in the Z order.
/// </summary>
Minimize = 6,
/// <summary>
/// Displays the window as a minimized window. This value is similar to
/// <see cref="Win32.ShowWindowCommand.ShowMinimized"/>, except the
/// window is not activated.
/// </summary>
ShowMinNoActive = 7,
/// <summary>
/// Displays the window in its current size and position. This value is
/// similar to <see cref="Win32.ShowWindowCommand.Show"/>, except the
/// window is not activated.
/// </summary>
ShowNA = 8,
/// <summary>
/// Activates and displays the window. If the window is minimized or
/// maximized, the system restores it to its original size and position.
/// An application should specify this flag when restoring a minimized window.
/// </summary>
Restore = 9,
/// <summary>
/// Sets the show state based on the SW_* value specified in the
/// STARTUPINFO structure passed to the CreateProcess function by the
/// program that started the application.
/// </summary>
ShowDefault = 10,
/// <summary>
/// <b>Windows 2000/XP:</b> Minimizes a window, even if the thread
/// that owns the window is not responding. This flag should only be
/// used when minimizing windows from a different thread.
/// </summary>
ForceMinimize = 11
}
[Flags()]
public enum RedrawWindowFlags : uint
{
/// <summary>
/// Invalidates the rectangle or region that you specify in lprcUpdate or hrgnUpdate.
/// You can set only one of these parameters to a non-NULL value. If both are NULL, RDW_INVALIDATE invalidates the entire window.
/// </summary>
Invalidate = 0x1,
/// <summary>Causes the OS to post a WM_PAINT message to the window regardless of whether a portion of the window is invalid.</summary>
InternalPaint = 0x2,
/// <summary>
/// Causes the window to receive a WM_ERASEBKGND message when the window is repainted.
/// Specify this value in combination with the RDW_INVALIDATE value; otherwise, RDW_ERASE has no effect.
/// </summary>
Erase = 0x4,
/// <summary>
/// Validates the rectangle or region that you specify in lprcUpdate or hrgnUpdate.
/// You can set only one of these parameters to a non-NULL value. If both are NULL, RDW_VALIDATE validates the entire window.
/// This value does not affect internal WM_PAINT messages.
/// </summary>
Validate = 0x8,
NoInternalPaint = 0x10,
/// <summary>Suppresses any pending WM_ERASEBKGND messages.</summary>
NoErase = 0x20,
/// <summary>Excludes child windows, if any, from the repainting operation.</summary>
NoChildren = 0x40,
/// <summary>Includes child windows, if any, in the repainting operation.</summary>
AllChildren = 0x80,
/// <summary>Causes the affected windows, which you specify by setting the RDW_ALLCHILDREN and RDW_NOCHILDREN values, to receive WM_ERASEBKGND and WM_PAINT messages before the RedrawWindow returns, if necessary.</summary>
UpdateNow = 0x100,
/// <summary>
/// Causes the affected windows, which you specify by setting the RDW_ALLCHILDREN and RDW_NOCHILDREN values, to receive WM_ERASEBKGND messages before RedrawWindow returns, if necessary.
/// The affected windows receive WM_PAINT messages at the ordinary time.
/// </summary>
EraseNow = 0x200,
Frame = 0x400,
NoFrame = 0x800
}
[Flags()]
public enum SetWindowPosFlags : uint
{
/// <summary>If the calling thread and the thread that owns the window are attached to different input queues,
/// the system posts the request to the thread that owns the window. This prevents the calling thread from
/// blocking its execution while other threads process the request.</summary>
/// <remarks>SWP_ASYNCWINDOWPOS</remarks>
AsynchronousWindowPosition = 0x4000,
/// <summary>Prevents generation of the WM_SYNCPAINT message.</summary>
/// <remarks>SWP_DEFERERASE</remarks>
DeferErase = 0x2000,
/// <summary>Draws a frame (defined in the window's class description) around the window.</summary>
/// <remarks>SWP_DRAWFRAME</remarks>
DrawFrame = 0x0020,
/// <summary>Applies new frame styles set using the SetWindowLong function. Sends a WM_NCCALCSIZE message to
/// the window, even if the window's size is not being changed. If this flag is not specified, WM_NCCALCSIZE
/// is sent only when the window's size is being changed.</summary>
/// <remarks>SWP_FRAMECHANGED</remarks>
FrameChanged = 0x0020,
/// <summary>Hides the window.</summary>
/// <remarks>SWP_HIDEWINDOW</remarks>
HideWindow = 0x0080,
/// <summary>Does not activate the window. If this flag is not set, the window is activated and moved to the
/// top of either the topmost or non-topmost group (depending on the setting of the hWndInsertAfter
/// parameter).</summary>
/// <remarks>SWP_NOACTIVATE</remarks>
DoNotActivate = 0x0010,
/// <summary>Discards the entire contents of the client area. If this flag is not specified, the valid
/// contents of the client area are saved and copied back into the client area after the window is sized or
/// repositioned.</summary>
/// <remarks>SWP_NOCOPYBITS</remarks>
DoNotCopyBits = 0x0100,
/// <summary>Retains the current position (ignores X and Y parameters).</summary>
/// <remarks>SWP_NOMOVE</remarks>
IgnoreMove = 0x0002,
/// <summary>Does not change the owner window's position in the Z order.</summary>
/// <remarks>SWP_NOOWNERZORDER</remarks>
DoNotChangeOwnerZOrder = 0x0200,
/// <summary>Does not redraw changes. If this flag is set, no repainting of any kind occurs. This applies to
/// the client area, the nonclient area (including the title bar and scroll bars), and any part of the parent
/// window uncovered as a result of the window being moved. When this flag is set, the application must
/// explicitly invalidate or redraw any parts of the window and parent window that need redrawing.</summary>
/// <remarks>SWP_NOREDRAW</remarks>
DoNotRedraw = 0x0008,
/// <summary>Same as the SWP_NOOWNERZORDER flag.</summary>
/// <remarks>SWP_NOREPOSITION</remarks>
DoNotReposition = 0x0200,
/// <summary>Prevents the window from receiving the WM_WINDOWPOSCHANGING message.</summary>
/// <remarks>SWP_NOSENDCHANGING</remarks>
DoNotSendChangingEvent = 0x0400,
/// <summary>Retains the current size (ignores the cx and cy parameters).</summary>
/// <remarks>SWP_NOSIZE</remarks>
IgnoreResize = 0x0001,
/// <summary>Retains the current Z order (ignores the hWndInsertAfter parameter).</summary>
/// <remarks>SWP_NOZORDER</remarks>
IgnoreZOrder = 0x0004,
/// <summary>Displays the window.</summary>
/// <remarks>SWP_SHOWWINDOW</remarks>
ShowWindow = 0x0040,
}
// mystery
[DllImport("user32.dll")]
public static extern int SetWindowCompositionAttribute(IntPtr hwnd, ref WindowCompositionAttributeData data);
[StructLayout(LayoutKind.Sequential)]
public struct WindowCompositionAttributeData
{
public WindowCompositionAttribute Attribute;
public IntPtr Data;
public int SizeOfData;
}
public enum WindowCompositionAttribute
{
WCA_ACCENT_POLICY = 19
}
public enum AccentState
{
ACCENT_DISABLED = 0,
ACCENT_ENABLE_BLURBEHIND = 3,
ACCENT_ENABLE_ACRYLICBLURBEHIND = 4
}
[StructLayout(LayoutKind.Sequential)]
public struct AccentPolicy
{
public AccentState AccentState;
public int AccentFlags;
public int GradientColor;
public int AnimationId;
}
}
}
================================================
FILE: RoundedTB/MainWindow.xaml
================================================
<Window x:Class="RoundedTB.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:RoundedTB"
xmlns:tb="http://www.hardcodet.net/taskbar"
xmlns:wpfui="clr-namespace:WPFUI.Controls;assembly=WPFUI"
mc:Ignorable="d"
Style="{StaticResource UiWindow}"
Title="RoundedTB" Height="458" Width="718"
Background="#20808080"
d:Background="DarkGray"
Visibility = "Visible"
Opacity="0.001"
d:Opacity="1"
ResizeMode="NoResize"
>
<!--169, 393-->
<Grid x:Name="MainGrid" Margin="0,0,0,0" d:Margin="0,-16,0,0">
<Grid.RowDefinitions>
<RowDefinition Height="Auto" MinHeight="30" />
<RowDefinition />
</Grid.RowDefinitions>
<wpfui:TitleBar x:Name="mainTitleBar" Grid.Row="0" UseNotifyIcon="True" NotifyIconImage="pack://application:,,,/res/traydark.ico" NotifyIconTooltip="RoundedTB" ApplicationNavigation="True" Margin="0,0,0,0" Title="RoundedTB - Configuration" Icon="pack://application:,,,/RoundedTBCanary.ico" Height="51" ShowMaximize="False">
<wpfui:TitleBar.NotifyIconMenu>
<ContextMenu MouseEnter="ContextMenu_MouseEnter">
<CheckBox x:Name ="StartupCheckBox" Content="Run at startup" Click="Startup_Clicked"/>
<MenuItem x:Name="DebugMenuItem" Header="Debug" Visibility ="Hidden" Click="DebugMenuItem_Click" Height="0"/>
<MenuItem x:Name ="ShowMenuItem" Header="Show RoundedTB" Click="ShowMenuItem_Click"/>
<MenuItem x:Name ="CloseMenuItem" Header="Close RoundedTB" Click="CloseMenuItem_Click"/>
</ContextMenu>
</wpfui:TitleBar.NotifyIconMenu>
</wpfui:TitleBar>
<Grid Grid.Row="1">
<Grid Margin="0,0,10,0" HorizontalAlignment="Right" Width="202" Height="55" VerticalAlignment="Top">
<Label x:Name="cornerRadiusLabel" Content="Corner radius" HorizontalAlignment="Left" VerticalAlignment="Top"/>
<TextBox x:Name="cornerRadiusInput" TextWrapping="NoWrap" Text="" VerticalAlignment="Top" HorizontalAlignment="Left" Width="94" Margin="108,19,0,0" LostFocus="cornerRadiusInput_LostFocus"/>
<Slider x:Name="cornerRadiusSlider" Height="10" VerticalAlignment="Top" HorizontalAlignment="Left" Width="84" LargeChange="0" SmallChange="1" Focusable="False" Maximum="48" Orientation="Horizontal" Thumb.DragCompleted="cornerRadiusSlider_DragCompleted" ValueChanged="cornerRadiusSlider_ValueChanged" Margin="0,25,0,0"/>
</Grid>
<wpfui:Button x:Name="aboutButton" Appearance="Secondary" Margin="0,0,10,47" VerticalAlignment="Bottom" Content="Help" Click="aboutButton_Click" FontWeight="Normal" HorizontalAlignment="Right" Width="133" Height="31"/>
<wpfui:Button x:Name="applyButton" Margin="0,0,10,10" VerticalAlignment="Bottom" Content="Apply" Click="ApplyButton_Click" FontWeight="Normal" HorizontalAlignment="Right" Width="133" Height="32"/>
<Grid Width="202" Margin="0,190,10,0" VerticalAlignment="Top" HorizontalAlignment="Right" >
<Label x:Name="widgetWidthLabel" Content="Width" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="0,0,0,0" Width="60" Visibility="Hidden" />
<TextBox x:Name="widgetWidthInput" HorizontalAlignment="Left" Margin="0,17,0,0" TextWrapping="NoWrap" Text="" VerticalAlignment="Top" Width="60" Visibility="Hidden" />
<Label x:Name="clockWidthLabel" Content="Width" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="0,0,0,0" Width="60" Visibility="Hidden" />
<TextBox x:Name="clockWidthInput" HorizontalAlignment="Left" Margin="0,17,0,0" TextWrapping="NoWrap" Text="" VerticalAlignment="Top" Width="60" Visibility="Hidden" />
<CheckBox x:Name="dynamicCheckBox" Content="Dynamic mode" Margin="70,12,0,0" Padding="0" Checked="dynamicCheckBox_Checked" Unchecked="dynamicCheckBox_Unchecked" RenderTransformOrigin="1.763,4.069" Visibility="Visible" Width="116" HorizontalAlignment="Left" />
<CheckBox x:Name="showTrayCheckBox" Content="Show tray" Margin="70,12,0,0" Padding="0" Visibility="Hidden" HorizontalAlignment="Left" />
<CheckBox x:Name="showWidgetsCheckBox" Content="Show widget" Margin="70,12,0,0" Padding="0" Visibility="Hidden" HorizontalAlignment="Left" />
<CheckBox x:Name="showClockCheckBox" Content="Show clock" Margin="70,12,0,0" Padding="0" Visibility="Hidden" HorizontalAlignment="Left" />
</Grid>
<CheckBox x:Name="centredCheckBox" Content="Centred taskbar?" Margin="10,62,0,0" VerticalAlignment="Top" Visibility="Hidden"/>
<Button x:Name="splitHelpButton" Opacity="0.001" Content="Click me!" Margin="107,122,0,0" Click="splitHelpButton_Click" Height="32" Width="94" VerticalAlignment="Top" FontWeight="Normal" FontFamily="Segoe UI Semibold" Visibility="Hidden"/>
<Grid Width="500" Margin="15,0,0,15" HorizontalAlignment="Left" Height="110" VerticalAlignment="Bottom">
<CheckBox x:Name="showSegmentsOnHoverCheckBox" Content="Show segments only when hovered over with the mouse - PERFORMANCE ISSUES" Margin="0,0,0,0" VerticalAlignment="Top" Checked="showSegmentsOnHoverCheckBox_Checked" Unchecked="showSegmentsOnHoverCheckBox_Unchecked" HorizontalAlignment="Left" d:LayoutOverrides="HorizontalAlignment, VerticalAlignment"/>
<CheckBox x:Name="fillMaximisedCheckBox" Content="When a window is maximised, restore the taskbar" Margin="0,30,0,0" Checked="fillMaximisedCheckBox_Checked" Unchecked="fillMaximisedCheckBox_Unchecked" VerticalAlignment="Top" HorizontalAlignment="Left" d:LayoutOverrides="HorizontalAlignment, VerticalAlignment"/>
<CheckBox x:Name="fillAltTabCheckBox" Content="When alt+tab or win+tab is pressed, restore the taskbar" Margin="0,60,0,0" VerticalAlignment="Top" HorizontalAlignment="Left" d:LayoutOverrides="HorizontalAlignment"/>
<CheckBox x:Name="compositionFixCheckBox" Content="Improve compatibility with TranslucentTB and other mods (may cause flickering)" Margin="0,90,0,0" VerticalAlignment="Top" IsChecked="False" Checked="compositionFixCheckBox_Checked" HorizontalAlignment="Left" d:LayoutOverrides="HorizontalAlignment, VerticalAlignment"/>
</Grid>
<Grid Width="202" Height="110" Margin="0,70,10,0" HorizontalAlignment="Right" VerticalAlignment="Top">
<Label x:Name="mTopLabel" Content="Top Margin" HorizontalAlignment="Left" VerticalAlignment="Top" Width="94" Margin="0,0,0,0" d:LayoutOverrides="HorizontalAlignment, VerticalAlignment"/>
<TextBox x:Name="mTopInput" HorizontalAlignment="Left" Margin="0,20,0,0" TextWrapping="NoWrap" Text="" VerticalAlignment="Top" Width="94" d:LayoutOverrides="HorizontalAlignment, VerticalAlignment" LostFocus="mTopInput_LostFocus"/>
<Label x:Name="mBottomLabel" Content="Bottom Margin" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="108,0,0,0" Width="94" d:LayoutOverrides="HorizontalAlignment, VerticalAlignment"/>
<TextBox x:Name="mBottomInput" HorizontalAlignment="Left" Margin="108,20,0,0" TextWrapping="NoWrap" Text="" VerticalAlignment="Top" Width="94" d:LayoutOverrides="VerticalAlignment" LostFocus="mBottomInput_LostFocus"/>
<Label x:Name="mLeftLabel" Content="Left Margin" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="0,56,0,0" Width="94" d:LayoutOverrides="HorizontalAlignment"/>
<TextBox x:Name="mLeftInput" HorizontalAlignment="Left" Margin="0,76,0,0" TextWrapping="NoWrap" Text="" VerticalAlignment="Top" Width="94" d:LayoutOverrides="HorizontalAlignment" LostFocus="mLeftInput_LostFocus"/>
<Label x:Name="mRightLabel" Content="Right Margin" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="108,56,0,0" Width="84"/>
<TextBox x:Name="mRightInput" HorizontalAlignment="Left" Margin="108,76,0,0" TextWrapping="NoWrap" Text="" VerticalAlignment="Top" Width="94" LostFocus="mRightInput_LostFocus"/>
</Grid>
<Grid x:Name="tbDiagramGrid" Margin="10,0,0,0" Height="247" VerticalAlignment="Top" HorizontalAlignment="Left" Width="486">
<Rectangle Stroke="#30242424" Fill="#20808080" RadiusX="5" RadiusY="5"/>
<wpfui:Button x:Name="taskbarRectStandIn" Margin="126,0,126,5" VerticalAlignment="Bottom" Click="taskbarRectStandIn_Click" Appearance="Primary" Height="32"></wpfui:Button>
<wpfui:Button x:Name="trayRectStandIn" Margin="415,0,5,5" Click="trayRectStandIn_Click" VerticalAlignment="Bottom" Height="32" Appearance="Secondary" Padding="0">📅</wpfui:Button>
<wpfui:Button x:Name="widgetsRectStandIn" Margin="5,0,415,5" Click="widgetsRectStandIn_Click" VerticalAlignment="Bottom" Height="32" Appearance="Secondary" Padding="0">📰</wpfui:Button>
<wpfui:Button x:Name="clockRectStandIn" Margin="415,0,5,60" Click="clockRectStandIn_Click" VerticalAlignment="Bottom" Height="32" Appearance="Secondary" VerticalContentAlignment="Center" Padding="0">🕑</wpfui:Button>
<Label Content="RoundedTB" HorizontalAlignment="Center" Margin="0,59,0,108" FontFamily="Segoe UI Variable Display" FontWeight="SemiBold" FontSize="60" Opacity="0.75"/>
<Label Content="To begin, select a taskbar segment below." HorizontalAlignment="Center" Margin="0,138,0,75" FontFamily="Segoe UI Variable Display" FontWeight="SemiBold" FontSize="20" Opacity="0.75"/>
</Grid>
<Grid Margin="0,0,10,83" HorizontalAlignment="Right" Width="133" Height="50" VerticalAlignment="Bottom">
<Label Content="Auto-hide" Height="20" VerticalAlignment="Top"/>
<ComboBox x:Name="autoHideComboBox" Margin="0,18,0,0" VerticalAlignment="Top">
<ComboBoxItem>Always show</ComboBoxItem>
<ComboBoxItem>Always hide</ComboBoxItem>
<ComboBoxItem>[unavailable]</ComboBoxItem>
</ComboBox>
</Grid>
<Rectangle HorizontalAlignment="Center" Margin="0,262,0,0" Stroke="#4C909090" Width="698" RadiusX="1" RadiusY="1.5" Height="1" VerticalAlignment="Top"/>
</Grid>
</Grid>
</Window>
================================================
FILE: RoundedTB/MainWindow.xaml.cs
================================================
using IWshRuntimeLibrary;
using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.IO;
using System.Runtime.InteropServices;
using System.Windows;
using System.Reflection;
using System.Windows.Threading;
using System.Windows.Interop;
using DesktopBridge;
using System.Threading.Tasks;
using Windows.ApplicationModel;
using System.Diagnostics;
using Microsoft.Win32;
using System.Text;
using WPFUI;
using System.Windows.Media;
using System.Linq;
using System.Windows.Controls;
namespace RoundedTB
{
/// <summary>
/// Interaction logic for MainWindow.xaml
///
/// Many thanks to
/// - FloatingMilkshake
/// - cardin
/// - cleverActon0126
/// for your gracious donations! 💖
///
/// </summary>
public partial class MainWindow : Window
{
public bool isWindows11;
public List<Types.Taskbar> taskbarDetails = new List<Types.Taskbar>();
public bool shouldReallyDieNoReally = false;
public string configPath = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData), "rtb.json");
public string logPath = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData), "rtb.log");
public Types.Settings activeSettings = new Types.Settings();
public BackgroundWorker taskbarThread = new BackgroundWorker();
public IntPtr hwndDesktopButton = IntPtr.Zero;
public int lastDynDistance = 0;
public int numberToForceRefresh = 0;
public bool isCentred = false;
public bool isAlreadyRunning = false;
public Background background;
public Interaction interaction;
private HwndSource source;
public int selectedSegment = 0; // 0 = Simple, 1 = AppList, 2 = Tray, 3 = Widgets
/// <summary>
/// Versions:
/// -1: Canary
/// 0: R3.0
/// 1: P3.1B
/// 2: R3.1
/// 3: R4
/// </summary>
public int version = -1;
private VisiblityControlManager rectStands;
record VisiblityControlSet(WPFUI.Controls.Button KeyControl, IList<System.Windows.Controls.Control> FollowingControls);
record VisiblityControlManager(VisiblityControlSet CenterBar, VisiblityControlSet TaskTray, VisiblityControlSet Widgets, VisiblityControlSet Clock)
{
public IReadOnlyList<VisiblityControlSet> All => new[] { CenterBar, TaskTray, Widgets, Clock };
public IReadOnlyList<VisiblityControlSet> AllWithoutCenterBar => new[] { TaskTray, Widgets, Clock };
public VisiblityControlSet At(int no) => All[no - 1];
internal void Focus(VisiblityControlSet set)
{
set.KeyControl.Appearance = WPFUI.Common.Appearance.Primary;
foreach (var c in set.FollowingControls)
{
c.Visibility = Visibility.Visible;
}
All.Except(new[] { set }).ForEach(x =>
{
x.KeyControl.Appearance = WPFUI.Common.Appearance.Secondary;
foreach (var c in x.FollowingControls)
{
c.Visibility = Visibility.Hidden;
}
});
}
}
public MainWindow()
{
WPFUI.Background.Manager.Apply(WPFUI.Background.BackgroundType.Mica, this);
InitializeComponent();
rectStands = new(
new VisiblityControlSet(taskbarRectStandIn, new[] { dynamicCheckBox }),
new VisiblityControlSet(trayRectStandIn, new[] { showTrayCheckBox }),
new VisiblityControlSet(widgetsRectStandIn, new Control[] { showWidgetsCheckBox, widgetWidthInput, widgetWidthLabel }),
new VisiblityControlSet(clockRectStandIn, new Control[] { showClockCheckBox, clockWidthInput, clockWidthLabel })
);
// Check OS build, as behaviours rather-annoyingly differ between Windows 11 and Windows 10
RegistryKey registryKey = Registry.LocalMachine.OpenSubKey(@"SOFTWARE\Microsoft\Windows NT\CurrentVersion");
var buildNumber = registryKey.GetValue("CurrentBuild").ToString();
if (Convert.ToInt32(buildNumber) >= 21996)
{
isWindows11 = true;
}
else
{
isWindows11 = false;
activeSettings.IsWindows11 = false;
dynamicCheckBox.Content = "Split mode";
fillAltTabCheckBox.Content = "[Unavailable]";
}
// Initialise functions
background = new Background();
interaction = new Interaction();
// Check if RoundedTB is already running, and if it is, do nothing.
Process[] matchingProcesses = Process.GetProcessesByName(Process.GetCurrentProcess().ProcessName);
if (matchingProcesses.Length > 1)
{
List<IntPtr> windowList = Interaction.GetTopLevelWindows();
foreach (IntPtr hwnd in windowList)
{
StringBuilder windowClass = new StringBuilder(1024);
StringBuilder windowTitle = new StringBuilder(1024);
try
{
LocalPInvoke.GetClassName(hwnd, windowClass, 1024);
LocalPInvoke.GetWindowText(hwnd, windowTitle, 1024);
if (windowClass.ToString().Contains("HwndWrapper[RoundedTB.exe") && windowTitle.ToString() == "RoundedTB")
{
LocalPInvoke.SetWindowText(hwnd, "RoundedTB_SettingsRequest");
}
}
catch (Exception) { }
}
shouldReallyDieNoReally = true;
isAlreadyRunning = true;
Close();
return;
}
TrayIconCheck(isForceReset:true);
if (IsRunningAsUWP())
{
#pragma warning disable CS4014
StartupInit(true);
configPath = Path.Combine(Windows.Storage.ApplicationData.Current.RoamingFolder.Path, "rtb.json");
logPath = Path.Combine(Windows.Storage.ApplicationData.Current.RoamingFolder.Path, "rtb.log");
}
if (System.IO.File.Exists(Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.Startup), "RoundedTB.lnk")) && !IsRunningAsUWP())
{
StartupCheckBox.IsChecked = true;
ShowMenuItem.Header = "Show RoundedTB";
}
taskbarThread.WorkerSupportsCancellation = true;
taskbarThread.WorkerReportsProgress = true;
taskbarThread.DoWork += background.DoWork;
// Load settings into memory/UI
interaction.FileSystem();
if (!IsRunningAsUWP())
{
interaction.AddLog($"RoundedTB started!");
}
else
{
interaction.AddLog($"RoundedTB started in UWP mode!");
}
activeSettings = interaction.ReadJSON();
if (isWindows11)
{
activeSettings.IsWindows11 = true;
}
else
{
activeSettings.IsWindows11 = false;
}
// Default settings
if (activeSettings == null)
{
if (isWindows11) // Default settings for Windows 11
{
activeSettings = new Types.Settings()
{
SimpleTaskbarLayout = new Types.SegmentSettings { CornerRadius = 7, MarginLeft = 3, MarginTop = 3, MarginRight = 3, MarginBottom = 3 },
DynamicAppListLayout = new Types.SegmentSettings { CornerRadius = 7, MarginLeft = 3, MarginTop = 3, MarginRight = 3, MarginBottom = 3 },
DynamicTrayLayout = new Types.SegmentSettings { CornerRadius = 7, MarginLeft = 3, MarginTop = 3, MarginRight = 3, MarginBottom = 3 },
DynamicWidgetsLayout = new Types.SegmentSettings { CornerRadius = 7, MarginLeft = 3, MarginTop = 3, MarginRight = 3, MarginBottom = 3 },
WidgetsWidth = 168,
ClockWidth = 110,
IsDynamic = false,
IsCentred = false,
IsWindows11 = true,
ShowTray = false,
ShowWidgets = false,
ShowSecondaryClock = false,
CompositionCompat = false,
IsNotFirstLaunch = false,
FillOnMaximise = true,
FillOnTaskSwitch = true,
ShowSegmentsOnHover = false,
AutoHide = 0
};
}
else // Default settings for Windows 10
{
activeSettings = new Types.Settings()
{
SimpleTaskbarLayout = new Types.SegmentSettings { CornerRadius = 16, MarginLeft = 2, MarginTop = 2, MarginRight = 2, MarginBottom = 2 },
DynamicAppListLayout = new Types.SegmentSettings { CornerRadius = 16, MarginLeft = 2, MarginTop = 2, MarginRight = 2, MarginBottom = 2 },
DynamicTrayLayout = new Types.SegmentSettings { CornerRadius = 16, MarginLeft = 2, MarginTop = 2, MarginRight = 2, MarginBottom = 2 },
DynamicWidgetsLayout = new Types.SegmentSettings { CornerRadius = 16, MarginLeft = 2, MarginTop = 2, MarginRight = 2, MarginBottom = 2 },
WidgetsWidth = 168,
ClockWidth = 110,
IsDynamic = false,
IsCentred = false,
IsWindows11 = false,
ShowTray = false,
ShowWidgets = false,
ShowSecondaryClock = false,
CompositionCompat = false,
IsNotFirstLaunch = false,
FillOnMaximise = true,
FillOnTaskSwitch = false,
ShowSegmentsOnHover = false,
AutoHide = 0
};
}
}
if (version != activeSettings.Version && version != -1)
{
activeSettings.IsNotFirstLaunch = false;
}
activeSettings.Version = version;
interaction.AddLog($"Settings loaded:");
interaction.AddLog(
$"SimpleTaskbarLayout: {activeSettings.SimpleTaskbarLayout}\n" +
$"DynamicAppListLayout: {activeSettings.DynamicAppListLayout}\n" +
$"DynamicTrayLayout: {activeSettings.DynamicTrayLayout}\n" +
$"DynamicWidgetsLayout: {activeSettings.DynamicWidgetsLayout}\n" +
$"DynamicSecondaryClockLayout: {activeSettings.DynamicSecondaryClockLayout}\n" +
$"IsDynamic: {activeSettings.IsDynamic}\n" +
$"IsCentred: {activeSettings.IsCentred}\n" +
$"ShowTray: {activeSettings.ShowTray}\n" +
$"ShowWidgets: {activeSettings.ShowWidgets}\n" +
$"ShowSecondaryClock: {activeSettings.ShowSecondaryClock}\n" +
$"CompositionCompat: {activeSettings.CompositionCompat}\n" +
$"IsNotFirstLaunch: {activeSettings.IsNotFirstLaunch}\n" +
$"FillOnMaximise: {activeSettings.FillOnMaximise}\n" +
$"FillOnTaskSwitch: {activeSettings.FillOnTaskSwitch}\n" +
$"ShowTrayOnHover: {activeSettings.ShowSegmentsOnHover}\n"
);
// Checks if advanced margins are configured
if (activeSettings.IsDynamic)
{
cornerRadiusInput.Text = activeSettings.DynamicAppListLayout.CornerRadius.ToString();
cornerRadiusSlider.Value = activeSettings.DynamicAppListLayout.CornerRadius;
mTopInput.Text = activeSettings.DynamicAppListLayout.MarginTop.ToString();
mLeftInput.Text = activeSettings.DynamicAppListLayout.MarginLeft.ToString();
mBottomInput.Text = activeSettings.DynamicAppListLayout.MarginBottom.ToString();
mRightInput.Text = activeSettings.DynamicAppListLayout.MarginRight.ToString();
selectedSegment = 1;
}
else
{
cornerRadiusInput.Text = activeSettings.SimpleTaskbarLayout.CornerRadius.ToString();
cornerRadiusSlider.Value = activeSettings.SimpleTaskbarLayout.CornerRadius;
mTopInput.Text = activeSettings.SimpleTaskbarLayout.MarginTop.ToString();
mLeftInput.Text = activeSettings.SimpleTaskbarLayout.MarginLeft.ToString();
mBottomInput.Text = activeSettings.SimpleTaskbarLayout.MarginBottom.ToString();
mRightInput.Text = activeSettings.SimpleTaskbarLayout.MarginRight.ToString();
selectedSegment = 0;
}
// Get whether or not taskbar is centred
try
{
using (RegistryKey key = Registry.CurrentUser.OpenSubKey("Software\\Microsoft\\Windows\\CurrentVersion\\Explorer\\Advanced"))
{
if (key != null)
{
int val = (int)key.GetValue("TaskbarAl");
if (val == 1)
{
isCentred = true;
}
else
{
isCentred = false;
}
interaction.AddLog($"Taskbar centred? {isCentred}");
}
}
}
catch (Exception aaaa)
{
interaction.AddLog(aaaa.Message);
}
if (!isWindows11)
{
activeSettings.IsCentred = false;
}
// Copy and apply settings to UI
dynamicCheckBox.IsChecked = activeSettings.IsDynamic;
centredCheckBox.IsChecked = activeSettings.IsCentred;
showTrayCheckBox.IsChecked = activeSettings.ShowTray;
showWidgetsCheckBox.IsChecked = activeSettings.ShowWidgets;
showClockCheckBox.IsChecked = activeSettings.ShowSecondaryClock;
fillMaximisedCheckBox.IsChecked = activeSettings.FillOnMaximise;
fillAltTabCheckBox.IsChecked = activeSettings.FillOnTaskSwitch;
showSegmentsOnHoverCheckBox.IsChecked = activeSettings.ShowSegmentsOnHover;
compositionFixCheckBox.IsChecked = activeSettings.CompositionCompat;
autoHideComboBox.SelectedIndex = activeSettings.AutoHide;
widgetWidthInput.Text = activeSettings.WidgetsWidth.ToString();
clockWidthInput.Text = activeSettings.ClockWidth.ToString();
taskbarDetails = Taskbar.GenerateTaskbarInfo(isWindows11);
ApplyButton_Click(null, null);
if (!activeSettings.FillOnMaximise)
{
activeSettings.FillOnTaskSwitch = false;
fillAltTabCheckBox.IsEnabled = false;
}
//Showhide the split mode help button
if (!isWindows11 && activeSettings.IsDynamic)
{
splitHelpButton.Visibility = Visibility.Visible;
}
else
{
splitHelpButton.Visibility = Visibility.Hidden;
}
if (activeSettings.IsNotFirstLaunch != true)
{
activeSettings.IsNotFirstLaunch = true;
AboutWindow aw = new AboutWindow();
aw.expander0.IsExpanded = true;
aw.ShowDialog();
try
{
Visibility = Visibility.Visible;
}
catch (InvalidOperationException)
{
}
ShowMenuItem.Header = "Hide RoundedTB";
}
AutoHide(true, taskbarDetails);
UpdateUi();
}
public void UpdateUi()
{
if (!activeSettings.ShowTray || activeSettings.ShowSegmentsOnHover)
{
trayRectStandIn.Opacity = 0.5;
}
else
{
trayRectStandIn.Opacity = 1;
}
if (!activeSettings.ShowWidgets || activeSettings.ShowSegmentsOnHover)
{
widgetsRectStandIn.Opacity = 0.5;
}
else
{
widgetsRectStandIn.Opacity = 1;
}
rectStands.AllWithoutCenterBar.ForEach(x => x.KeyControl.Visibility = Visibility.Hidden);
if (activeSettings.IsCentred && activeSettings.IsWindows11 && activeSettings.IsDynamic)
{
taskbarRectStandIn.Margin = new Thickness(126, 0, 126, 5);
rectStands.AllWithoutCenterBar.ForEach(x => x.KeyControl.Visibility = Visibility.Visible);
}
else if (activeSettings.IsDynamic)
{
taskbarRectStandIn.Margin = new Thickness(5, 0, 247, 5);
trayRectStandIn.Visibility = Visibility.Visible;
}
else
{
taskbarRectStandIn.Margin = new Thickness(5, 210, 5, 5);
}
}
public void AutoHide(bool enabled, List<Types.Taskbar> taskbarDetails)
{
int workingHeight = System.Windows.Forms.Screen.PrimaryScreen.WorkingArea.Height;
int boundsHeight = System.Windows.Forms.Screen.PrimaryScreen.Bounds.Height;
int taskbarHeight = taskbarDetails[0].TaskbarRect.Bottom - taskbarDetails[0].TaskbarRect.Top;
bool workAreaMisconfigured = false;
if (boundsHeight - taskbarHeight > workingHeight)
{
workAreaMisconfigured = true;
}
if (activeSettings.AutoHide > 0 && enabled)
{
MonitorStuff.DisplayInfoCollection Displays = MonitorStuff.GetDisplays();
foreach (MonitorStuff.DisplayInfo display in Displays)
{
LocalPInvoke.RECT workArea = display.MonitorArea;
workArea.Bottom = workArea.Bottom - 2;
Interaction.SetWorkspace(workArea);
}
foreach (Types.Taskbar taskbar in taskbarDetails)
{
LocalPInvoke.SetWindowPos(taskbar.TaskbarHwnd, new IntPtr(-1), 0, 0, 0, 0, LocalPInvoke.SetWindowPosFlags.IgnoreMove | LocalPInvoke.SetWindowPosFlags.IgnoreResize);
Taskbar.SetTaskbarState(LocalPInvoke.AppBarStates.AlwaysOnTop, taskbar.TaskbarHwnd);
}
}
else if (!enabled)
{
foreach (Types.Taskbar taskbar in taskbarDetails)
{
LocalPInvoke.SetWindowPos(taskbar.TaskbarHwnd, new IntPtr(-1), 0, 0, 0, 0, LocalPInvoke.SetWindowPosFlags.IgnoreMove | LocalPInvoke.SetWindowPosFlags.IgnoreResize);
if (workAreaMisconfigured)
{
Taskbar.SetTaskbarState(LocalPInvoke.AppBarStates.AutoHide, taskbar.TaskbarHwnd);
Taskbar.SetTaskbarState(LocalPInvoke.AppBarStates.AlwaysOnTop, taskbar.TaskbarHwnd);
}
MonitorStuff.DisplayInfoCollection Displays = MonitorStuff.GetDisplays();
foreach (MonitorStuff.DisplayInfo display in Displays)
{
taskbarHeight = taskbar.TaskbarRect.Bottom - taskbar.TaskbarRect.Top;
LocalPInvoke.RECT workArea = display.MonitorArea;
workArea.Bottom = workArea.Bottom - taskbarHeight;
Interaction.SetWorkspace(workArea);
}
}
}
}
public void TrayIconCheck(bool isForceReset)
{
Uri resLight = new("pack://application:,,,/res/traylight.ico");
Uri resDark = new("pack://application:,,,/res/traydark.ico");
if (false)
{
// TODO: Show system theme mode icon.
bool cuurentIsLightMode = IsThemeLightMode();
if (cuurentIsLightMode)
{
mainTitleBar.NotifyIconImage = System.Windows.Media.Imaging.BitmapFrame.Create(
new System.Windows.Media.Imaging.BitmapImage(resLight));
}
else
{
mainTitleBar.NotifyIconImage = System.Windows.Media.Imaging.BitmapFrame.Create(
new System.Windows.Media.Imaging.BitmapImage(resDark));
}
}
if (isForceReset)
{
mainTitleBar.ResetIcon();
}
}
public bool IsThemeLightMode()
{
if (this.isWindows11)
{
return IsThemeLightModeForWin11();
}
else
{
// To be removed in the future.
WPFUI.Theme.Style style = WPFUI.Theme.Manager.GetSystemTheme();
return (style == WPFUI.Theme.Style.Light);
}
}
private static bool IsThemeLightModeForWin11()
{
RegistryKey key = Registry.CurrentUser.OpenSubKey(@"Software\Microsoft\Windows\CurrentVersion\Themes\Personalize");
int sysLightTheme = (int)key.GetValue("SystemUsesLightTheme");
bool isLight = (sysLightTheme == 1);
return isLight;
}
public void ApplyButton_Click(object sender, RoutedEventArgs e)
{
int mt = 0;
int ml = 0;
int mb = 0;
int mr = 0;
int widgetWidth = 0;
int clockWidth = 0;
{
if ((!int.TryParse(mTopInput.Text, out mt) && mTopInput.Text != string.Empty)
|| (!int.TryParse(mLeftInput.Text, out ml) && mLeftInput.Text != string.Empty)
|| (!int.TryParse(mBottomInput.Text, out mb) && mBottomInput.Text != string.Empty)
|| (!int.TryParse(mRightInput.Text, out mr) && mRightInput.Text != string.Empty))
{
return;
}
if ((!int.TryParse(widgetWidthInput.Text, out widgetWidth) && widgetWidthInput.Text != string.Empty)
|| (!int.TryParse(clockWidthInput.Text, out clockWidth) && clockWidthInput.Text != string.Empty))
{
return;
}
}
activeSettings.WidgetsWidth = widgetWidth;
activeSettings.ClockWidth = clockWidth;
activeSettings.AutoHide = autoHideComboBox.SelectedIndex;
activeSettings.IsDynamic = (bool)dynamicCheckBox.IsChecked;
activeSettings.IsCentred = Taskbar.CheckIfCentred();
activeSettings.ShowTray = (bool)showTrayCheckBox.IsChecked;
activeSettings.ShowWidgets = (bool)showWidgetsCheckBox.IsChecked;
activeSettings.ShowSecondaryClock = (bool)showClockCheckBox.IsChecked;
activeSettings.CompositionCompat = (bool)compositionFixCheckBox.IsChecked;
activeSettings.FillOnMaximise = (bool)fillMaximisedCheckBox.IsChecked;
activeSettings.FillOnTaskSwitch = (bool)fillAltTabCheckBox.IsChecked;
activeSettings.ShowSegmentsOnHover = (bool)showSegmentsOnHoverCheckBox.IsChecked;
try
{
foreach (Types.Taskbar taskbar in taskbarDetails)
{
int isFullTest = taskbar.TrayRect.Left - taskbar.AppListRect.Right;
if (!activeSettings.IsDynamic || (isFullTest <= taskbar.ScaleFactor * 25 && isFullTest > 0 && taskbar.TrayRect.Left != 0))
{
Taskbar.UpdateSimpleTaskbar(taskbar, activeSettings);
}
else
{
Taskbar.UpdateDynamicTaskbar(taskbar, activeSettings);
}
}
}
catch (InvalidOperationException aaaa)
{
interaction.AddLog(aaaa.Message);
}
if (taskbarThread.IsBusy == false)
{
taskbarThread.RunWorkerAsync((mt, ml, mb, mr, 0));
}
else
{
taskbarThread.CancelAsync();
while (taskbarThread.IsBusy == true)
{
System.Windows.Forms.Application.DoEvents();
System.Threading.Thread.Sleep(100);
}
taskbarThread.RunWorkerAsync((mt, ml, mb, mr, 0));
}
if (activeSettings.AutoHide < 1)
{
AutoHide(false, taskbarDetails);
}
else
{
AutoHide(true, taskbarDetails);
}
interaction.WriteJSON();
TrayIconCheck(isForceReset: true);
UpdateUi();
}
protected override void OnClosing(CancelEventArgs e)
{
base.OnClosing(e);
if (shouldReallyDieNoReally == false)
{
e.Cancel = true;
Visibility = Visibility.Hidden;
ShowMenuItem.Header = "Show RoundedTB";
}
else
{
try
{
taskbarThread.CancelAsync();
}
catch (Exception aaaa)
{
interaction.AddLog(aaaa.Message);
}
while (taskbarThread.IsBusy == true)
{
System.Windows.Forms.Application.DoEvents();
System.Threading.Thread.Sleep(100);
}
try
{
foreach (var tbDeets in taskbarDetails)
{
Taskbar.ResetTaskbar(tbDeets, activeSettings);
}
if (activeSettings.AutoHide > 0)
{
AutoHide(false, taskbarDetails);
}
}
catch (InvalidOperationException aaaa)
{
interaction.AddLog($"Taskbar structure changed on exit:\n{aaaa.Message}");
}
interaction.AddLog("Exiting RoundedTB.");
}
if (!isAlreadyRunning)
{
interaction.WriteJSON();
}
}
private void CloseMenuItem_Click(object sender, RoutedEventArgs e)
{
// Close any popups - leave main window for now
for (int windowCount = App.Current.Windows.Count - 1; windowCount >= 0; windowCount--)
{
App.Current.Windows[windowCount].Close();
}
shouldReallyDieNoReally = true;
Close();
}
public void ShowMenuItem_Click(object sender, RoutedEventArgs e)
{
if (IsVisible == false)
{
Visibility = Visibility.Visible;
ShowMenuItem.Header = "Hide RoundedTB";
}
else
{
// Close any popups - leave main window for now
for (int windowCount = App.Current.Windows.Count - 1; windowCount >= 0; windowCount--)
{
App.Current.Windows[windowCount].Close();
}
Visibility = Visibility.Hidden;
ShowMenuItem.Header = "Show RoundedTB";
}
}
private async void Startup_Clicked(object sender, RoutedEventArgs e)
{
Debug.WriteLine("Startup toggled");
if (IsRunningAsUWP())
{
await StartupToggle();
await StartupInit(false);
}
else
{
if (System.IO.File.Exists(Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.Startup), "RoundedTB.lnk")))
{
System.IO.File.Delete(Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.Startup), "RoundedTB.lnk"));
}
else
{
EnableStartup();
}
}
}
public void EnableStartup()
{
try
{
string shortcutFolder = Environment.GetFolderPath(Environment.SpecialFolder.Startup);
if (!Directory.Exists(shortcutFolder))
{
Directory.CreateDirectory(shortcutFolder);
}
WshShell shellClass = new WshShell();
string rtbStartupLink = Path.Combine(shortcutFolder, "RoundedTB.lnk");
IWshShortcut shortcut = (IWshShortcut)shellClass.CreateShortcut(rtbStartupLink);
shortcut.TargetPath = Environment.GetCommandLineArgs()[0];
shortcut.IconLocation = Environment.GetCommandLineArgs()[0];
shortcut.Arguments = "";
shortcut.Description = "Start RoundedTB";
shortcut.Save();
}
catch (Exception)
{
}
}
async Task StartupToggle()
{
StartupTask startupTask = await StartupTask.GetAsync("RTB"); // Pass the task ID you specified in the appxmanifest file
switch (startupTask.State)
{
case StartupTaskState.Disabled:
StartupTaskState newState = await startupTask.RequestEnableAsync();
StartupCheckBox.IsEnabled = true;
break;
case StartupTaskState.DisabledByUser:
StartupCheckBox.IsEnabled = false;
break;
case StartupTaskState.EnabledByPolicy:
StartupCheckBox.IsEnabled = false;
break;
case StartupTaskState.DisabledByPolicy:
StartupCheckBox.IsEnabled = false;
break;
case StartupTaskState.Enabled:
startupTask.Disable();
StartupCheckBox.IsEnabled = true;
break;
}
}
async Task StartupInit(bool clean)
{
StartupTask startupTask = await StartupTask.GetAsync("RTB");
switch (startupTask.State)
{
case StartupTaskState.Disabled:
StartupCheckBox.IsChecked = false;
StartupCheckBox.IsEnabled = true;
if (clean)
{
Visibility = Visibility.Visible;
ShowMenuItem.Header = "Hide RoundedTB";
}
StartupCheckBox.Content = "Run at startup";
break;
case StartupTaskState.DisabledByUser:
StartupCheckBox.IsChecked = false;
StartupCheckBox.IsEnabled = false;
if (clean)
{
Visibility = Visibility.Visible;
ShowMenuItem.Header = "Hide RoundedTB";
}
StartupCheckBox.Content = "Startup unavailable";
break;
case StartupTaskState.EnabledByPolicy:
StartupCheckBox.IsChecked = true;
StartupCheckBox.IsEnabled = false;
if (clean)
{
Visibility = Visibility.Hidden;
ShowMenuItem.Header = "Show RoundedTB";
}
StartupCheckBox.Content = "Startup mandatory";
break;
case StartupTaskState.DisabledByPolicy:
StartupCheckBox.IsChecked = false;
StartupCheckBox.IsEnabled = false;
if (clean)
{
Visibility = Visibility.Visible;
ShowMenuItem.Header = "Hide RoundedTB";
}
StartupCheckBox.Content = "Startup unavailable";
break;
case StartupTaskState.Enabled:
StartupCheckBox.IsChecked = true;
StartupCheckBox.IsEnabled = true;
if (clean)
{
Visibility = Visibility.Hidden;
ShowMenuItem.Header = "Show RoundedTB";
}
StartupCheckBox.Content = "Run at startup";
break;
}
}
// Checks if running as a UWP app
public bool IsRunningAsUWP()
{
try
{
Helpers helpers = new Helpers();
return helpers.IsRunningAsUwp();
}
catch (Exception)
{
return false;
}
}
private void DebugMenuItem_Click(object sender, RoutedEventArgs e)
{
IntPtr hwndNext = LocalPInvoke.FindWindowExA(taskbarDetails[0].TaskbarHwnd, IntPtr.Zero, "Start", null);
List<IntPtr> floatingMilkshakesBitsOfTaskbar = new List<IntPtr>();
floatingMilkshakesBitsOfTaskbar.Add(hwndNext);
while (true)
{
hwndNext = LocalPInvoke.FindWindowExA(taskbarDetails[0].TaskbarHwnd, hwndNext, null, null);
if (floatingMilkshakesBitsOfTaskbar.Contains(hwndNext))
{
break;
}
floatingMilkshakesBitsOfTaskbar.Add(hwndNext);
}
foreach (IntPtr hwnd in floatingMilkshakesBitsOfTaskbar)
{
LocalPInvoke.GetWindowRect(hwnd, out LocalPInvoke.RECT rect);
LocalPInvoke.MoveWindow(hwnd, rect.Left + 50, rect.Top, (rect.Right + 50) - (rect.Left + 50), rect.Bottom - rect.Top, true);
}
}
private async void ContextMenu_MouseEnter(object sender, System.Windows.Input.MouseEventArgs e)
{
if (IsRunningAsUWP())
{
await StartupInit(false);
}
}
private void dynamicCheckBox_Checked(object sender, RoutedEventArgs e)
{
centredCheckBox.IsEnabled = true;
showSegmentsOnHoverCheckBox.IsEnabled = true;
showSegmentsOnHoverCheckBox.IsChecked = false;
showTrayCheckBox.IsEnabled = true;
showTrayCheckBox.IsChecked = true;
if (!isWindows11)
{
splitHelpButton.Visibility = Visibility.Visible;
if (Opacity > 0.5)
{
splitHelpButton_Click(null, null);
}
}
}
private void dynamicCheckBox_Unchecked(object sender, RoutedEventArgs e)
{
centredCheckBox.IsEnabled = false;
centredCheckBox.IsChecked = false;
showSegmentsOnHoverCheckBox.IsEnabled = false;
showSegmentsOnHoverCheckBox.IsChecked = false;
showTrayCheckBox.IsEnabled = false;
showTrayCheckBox.IsChecked = false;
if (!isWindows11)
{
splitHelpButton.Visibility = Visibility.Hidden;
}
}
private void cornerRadiusSlider_DragCompleted(object sender, System.Windows.Controls.Primitives.DragCompletedEventArgs e)
{
int check = Convert.ToInt32(Math.Round(cornerRadiusSlider.Value));
cornerRadiusInput.Text = check.ToString();
switch (selectedSegment)
{
default:
break;
case 0:
activeSettings.SimpleTaskbarLayout.CornerRadius = check;
break;
case 1:
activeSettings.DynamicAppListLayout.CornerRadius = check;
break;
case 2:
activeSettings.DynamicTrayLayout.CornerRadius = check;
break;
case 3:
activeSettings.DynamicWidgetsLayout.CornerRadius = check;
break;
case 4:
activeSettings.DynamicSecondaryClockLayout.CornerRadius = check;
break;
}
}
protected override void OnSourceInitialized(EventArgs e)
{
Debug.WriteLine("AAAAA");
base.OnSourceInitialized(e);
IntPtr handle = new WindowInteropHelper(this).Handle;
source = HwndSource.FromHwnd(handle);
source.AddHook(interaction.HwndHook);
bool wtf = LocalPInvoke.RegisterHotKey(handle, 9000, 0x8, 0x71);
Debug.WriteLine("KEY: " + wtf);
Debug.WriteLine(handle);
Debug.WriteLine((int)Types.KeyModifier.WinKey);
Debug.WriteLine(System.Windows.Forms.Keys.J.GetHashCode());
Visibility = Visibility.Hidden;
Opacity = 1;
}
private void splitHelpButton_Click(object sender, RoutedEventArgs e)
{
Infobox ib = new Infobox();
ib.Title = "RoundedTB - Split mode configuration";
ib.titleBlock.Text = "How to use Split Mode";
ib.bodyBlock.Text = "Split mode has a couple of limitations and requires a small amount of setup to get working properly.\n\nLimitations:\n1) Split mode doesn't resize itself automatically. This feature will be coming to RoundedTB for Windows 10 in the future.\n2) Toolbars are not compatible with split mode currently, and will need to be disabled apart from one (more on that in a moment).\n3) Split mode only works when the taskbar is horizontal at the top or bottom of the screen.\n\nSetup:\n1) Right-click the taskbar and disable \"Lock the taskbar\".\n2) Right-click it again and turn off any existing toolbars.\n3) Right-click a third time, select Toolbars > Desktop.\n4) Use the small || handle to resize the taskbar as you please.";
ib.ShowDialog();
}
private void compositionFixCheckBox_Checked(object sender, RoutedEventArgs e)
{
if (Opacity > 0.01)
{
Infobox ib = new Infobox();
ib.Height = 450;
ib.Title = "RoundedTB - TranslucentTB compatibility";
ib.titleBlock.Text = "Compatibility with TranslucentTB";
ib.bodyBlock.Text = "\nTranslucentTB is a utility that allows you to customise the opacity, blur and colour of the taskbar seamlessly with significantly finer control than other tools. Enable this option to allow RoundedTB and TranslucentTB to work together.\n\nThis is necessary due to a bug in Windows (it's not the fault of RoundedTB or TranslucentTB), and you might encounter some minor flickering when the taskbar \"updates\" (changes size, roundness or position). This is usually pretty minimal and many people use RoundedTB and TranslucentTB in tandem without complaint, but if it bothers you then I recommend sticking with either RoundedTB or TranslucentTB until a better solution is available.\n\nRegardless though, go show TranslucentTB some love! It's the OG Windows 10 aesthetic taskbar mod, the first one on the Microsoft Store and the project that inspired me to make RoundedTB. Plus, the dev is pretty awesome 💖";
ib.ShowDialog();
}
}
private void aboutButton_Click(object sender, RoutedEventArgs e)
{
AboutWindow aw = new AboutWindow();
aw.ShowDialog();
}
private void fillMaximisedCheckBox_Checked(object sender, RoutedEventArgs e)
{
if (isWindows11)
{
fillAltTabCheckBox.IsEnabled = true;
}
}
private void fillMaximisedCheckBox_Unchecked(object sender, RoutedEventArgs e)
{
fillAltTabCheckBox.IsEnabled = false;
fillAltTabCheckBox.IsChecked = false;
}
private void showSegmentsOnHoverCheckBox_Checked(object sender, RoutedEventArgs e)
{
showTrayCheckBox.IsEnabled = false;
showTrayCheckBox.IsChecked = false;
showWidgetsCheckBox.IsEnabled = false;
showWid
gitextract_2jsysl7i/ ├── .gitattributes ├── .github/ │ └── workflows/ │ └── ci.yml ├── .gitignore ├── AnalysisReport.sarif ├── LICENSE ├── PackagingProject/ │ ├── Package.appxmanifest │ └── RoundedTB.Package.wapproj ├── README.md ├── RoundedTB/ │ ├── .editorconfig │ ├── AboutWindow.xaml │ ├── AboutWindow.xaml.cs │ ├── App.config │ ├── App.xaml │ ├── App.xaml.cs │ ├── AppBars.cs │ ├── Background.cs │ ├── EnumerableExtensions.cs │ ├── FodyWeavers.xml │ ├── IAppVisibility.cs │ ├── Infobox.xaml │ ├── Infobox.xaml.cs │ ├── Interaction.cs │ ├── LocalPInvoke.cs │ ├── MainWindow.xaml │ ├── MainWindow.xaml.cs │ ├── MonitorStuff.cs │ ├── Properties/ │ │ ├── AssemblyInfo.cs │ │ ├── Resources.Designer.cs │ │ ├── Resources.resx │ │ ├── Settings.Designer.cs │ │ └── Settings.settings │ ├── RoundedTB.csproj │ ├── Taskbar.cs │ ├── TaskbarEffect.xaml │ ├── TaskbarEffect.xaml.cs │ ├── Types.cs │ └── app.manifest ├── RoundedTB.sln └── upgrade-assistant.clef
SYMBOL INDEX (206 symbols across 16 files)
FILE: RoundedTB/AboutWindow.xaml.cs
class AboutWindow (line 22) | public partial class AboutWindow : Window
method AboutWindow (line 24) | public AboutWindow()
method okButton_Click (line 30) | private void okButton_Click(object sender, RoutedEventArgs e)
method Hyperlink_RequestNavigate (line 34) | private void Hyperlink_RequestNavigate(object sender, RequestNavigateE...
method configButton_Click (line 39) | private void configButton_Click(object sender, RoutedEventArgs e)
method logButton_Click (line 44) | private void logButton_Click(object sender, RoutedEventArgs e)
FILE: RoundedTB/App.xaml.cs
class App (line 14) | public partial class App : Application
method OnStartup (line 16) | protected override void OnStartup(StartupEventArgs e)
FILE: RoundedTB/AppBars.cs
class AppBars (line 6) | class AppBars
method SHAppBarMessage (line 8) | [DllImport("shell32.dll")]
type AppBarMessages (line 11) | public enum AppBarMessages
type APPBARDATA (line 26) | [StructLayout(LayoutKind.Sequential)]
type AppBarStates (line 37) | public enum AppBarStates
method SetAppbarState (line 47) | public static void SetAppbarState(IntPtr hwnd, AppBarStates option)
method GetAppbarState (line 60) | public static AppBarStates GetAppbarState(IntPtr hwnd)
method MakeAppbarSad (line 71) | public static void MakeAppbarSad(IntPtr hwnd)
method SetAppbarRect (line 82) | public static void SetAppbarRect(IntPtr hwnd, LocalPInvoke.RECT rc)
FILE: RoundedTB/Background.cs
class Background (line 11) | public class Background
type ReloadChecker (line 13) | private struct ReloadChecker
method Background (line 23) | public Background()
method DoWork (line 30) | public void DoWork(object sender, DoWorkEventArgs e)
FILE: RoundedTB/EnumerableExtensions.cs
class EnumerableExtensions (line 9) | public static class EnumerableExtensions
method ForEach (line 11) | public static void ForEach<T>(this IEnumerable<T> src, Action<T> action)
FILE: RoundedTB/IAppVisibility.cs
type MONITOR_APP_VISIBILITY (line 10) | public enum MONITOR_APP_VISIBILITY
type IAppVisibilityEvents (line 17) | [ComImport, Guid("6584CE6B-7D82-49C2-89C9-C6BC02BA8C38"), InterfaceType(...
method AppVisibilityOnMonitorChanged (line 20) | void AppVisibilityOnMonitorChanged(IntPtr hMonitor, MONITOR_APP_VISIBI...
method LauncherVisibilityChange (line 21) | void LauncherVisibilityChange([MarshalAs(UnmanagedType.Bool)] bool cur...
type IAppVisibility (line 24) | [ComImport, Guid("2246EA2D-CAEA-4444-A3C4-6DE827E44313"), InterfaceType(...
method GetAppVisibilityOnMonitor (line 27) | MONITOR_APP_VISIBILITY GetAppVisibilityOnMonitor(IntPtr hMonitor);
method IsLauncherVisible (line 29) | [return: MarshalAs(UnmanagedType.Bool)]
method Advise (line 32) | uint Advise(IAppVisibilityEvents pCallback);
method Unadvise (line 33) | void Unadvise(uint dwCookie);
class AppVisibility (line 36) | [ComImport, Guid("7E5FE3D9-985F-4908-91F9-EE19F9FD1514"), ClassInterface...
FILE: RoundedTB/Infobox.xaml.cs
class Infobox (line 20) | public partial class Infobox : Window
method Infobox (line 22) | public Infobox()
method okButton_Click (line 27) | private void okButton_Click(object sender, RoutedEventArgs e)
FILE: RoundedTB/Interaction.cs
class Interaction (line 13) | public class Interaction
method Interaction (line 18) | public Interaction()
method ReadJSON (line 30) | public Types.Settings ReadJSON()
method IsWindows11 (line 42) | public bool IsWindows11()
method WriteJSON (line 52) | public void WriteJSON()
method FileSystem (line 58) | public void FileSystem()
method SetWorkspace (line 119) | public static bool SetWorkspace(LocalPInvoke.RECT rect)
method AddLog (line 131) | public void AddLog(string message)
method IsTranslucentTBRunning (line 137) | public static bool IsTranslucentTBRunning()
method UpdateTranslucentTB (line 151) | public static IntPtr UpdateTranslucentTB(IntPtr taskbarHwnd)
method UpdateLegacyTB (line 157) | public static void UpdateLegacyTB(IntPtr taskbarHwnd)
method IsOdd (line 172) | public bool? IsOdd(int input)
method HwndHook (line 191) | public IntPtr HwndHook(IntPtr hwnd, int msg, IntPtr wParam, IntPtr lPa...
method IsAutoHideEnabled (line 224) | public static bool IsAutoHideEnabled()
method IsTaskbarVisibleOnMonitor (line 229) | public bool IsTaskbarVisibleOnMonitor(LocalPInvoke.RECT tbRectP, Local...
method GetTopLevelWindows (line 240) | public static List<IntPtr> GetTopLevelWindows()
method EnumWindow (line 259) | private static bool EnumWindow(IntPtr handle, IntPtr pointer)
method TaskbarOnMonitorWithMaximisedWindow (line 270) | public static bool TaskbarOnMonitorWithMaximisedWindow(IntPtr taskbarH...
method RefreshUiTray (line 275) | public void RefreshUiTray(bool isForceReset)
type TaskbarPosition (line 293) | public enum TaskbarPosition
class Taskbar (line 302) | public sealed class Taskbar
method Taskbar (line 341) | public Taskbar(IntPtr taskbarHandle)
FILE: RoundedTB/LocalPInvoke.cs
class LocalPInvoke (line 8) | public class LocalPInvoke
method SetWindowPos (line 10) | [DllImport("user32.dll", SetLastError = true)]
method RegisterHotKey (line 13) | [DllImport("user32.dll")]
method UnregisterHotKey (line 16) | [DllImport("user32.dll")]
method ShowWindow (line 19) | [DllImport("user32.dll")]
method RedrawWindow (line 22) | [DllImport("user32.dll")]
method SendMessage (line 25) | [DllImport("user32.dll", CharSet = CharSet.Auto)]
method PtInRect (line 28) | [DllImport("user32.dll")]
method IsWindow (line 31) | [DllImport("user32.dll")]
method GetWindowRgn (line 35) | [DllImport("user32.dll")]
method SetWindowRgn (line 38) | [DllImport("user32.dll")]
method CreateRoundRectRgn (line 41) | [DllImport("gdi32.dll")]
method CreateRectRgn (line 44) | [DllImport("gdi32.dll")]
method FindWindowExA (line 47) | [DllImport("user32.dll")]
method GetDpiForWindow (line 50) | [DllImport("user32.dll")]
method GetWindowRect (line 53) | [DllImport("user32.dll")]
method MonitorFromWindow (line 56) | [DllImport("user32.dll")]
method MoveWindow (line 59) | [DllImport("user32.dll")]
method GetWindowRect (line 62) | [DllImport("user32.dll")]
method CombineRgn (line 66) | [DllImport("gdi32.dll")]
method RegisterWindowMessage (line 69) | [DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Auto)]
method SHAppBarMessage (line 72) | [DllImport("shell32.dll", SetLastError = true)]
method FindWindow (line 75) | [DllImport("user32.dll", SetLastError = true)]
method GetCursorPos (line 78) | [DllImport("user32.dll", SetLastError = true)]
method ShowWindow (line 82) | [DllImport("user32.dll")]
method SystemParametersInfo (line 85) | [DllImport("user32.dll", CharSet = CharSet.Auto, SetLastError = true)]
method IsWindowVisible (line 89) | [DllImport("user32.dll")]
method DwmGetWindowAttribute (line 93) | [DllImport("dwmapi.dll")]
method EnumWindows (line 96) | [DllImport("user32.dll")]
method GetWindowPlacement (line 100) | [DllImport("user32.dll", SetLastError = true)]
method GetClassName (line 104) | [DllImport("user32.dll", SetLastError = true, EntryPoint = "GetClassNa...
method WindowFromPoint (line 107) | [DllImport("user32.dll")]
method GetWindowText (line 110) | [DllImport("user32.dll", CharSet = CharSet.Auto, SetLastError = true)]
method SetForegroundWindow (line 113) | [DllImport("user32.dll")]
method ShowWindowAsync (line 116) | [DllImport("user32.dll")]
method IsIconic (line 119) | [DllImport("user32.dll")]
method SetWindowText (line 122) | [DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Auto)]
method SHAppBarMessage (line 125) | [DllImport("shell32.dll")]
method SetLayeredWindowAttributes (line 128) | [DllImport("user32.dll")]
method SetWindowLong (line 131) | [DllImport("user32.dll")]
method GetWindowLong (line 134) | [DllImport("user32.dll")]
method GetLayeredWindowAttributes (line 137) | [DllImport("user32.dll", SetLastError = true)]
method DeleteObject (line 140) | [DllImport("gdi32.dll")]
type AppBarStates (line 149) | public enum AppBarStates
type DWMWINDOWATTRIBUTE (line 155) | public enum DWMWINDOWATTRIBUTE : uint
type ShowState (line 174) | public enum ShowState : int
type POINT (line 207) | public struct POINT
type RECT (line 213) | [StructLayout(LayoutKind.Sequential)]
type APPBARDATA (line 222) | [StructLayout(LayoutKind.Sequential)]
type ABM (line 233) | public enum ABM : uint
type ABE (line 248) | public enum ABE : uint
class ABS (line 256) | public static class ABS
type WINDOWPLACEMENT (line 265) | [Serializable]
type ShowWindowCommands (line 316) | public enum ShowWindowCommands
type RedrawWindowFlags (line 388) | [Flags()]
type SetWindowPosFlags (line 438) | [Flags()]
method SetWindowCompositionAttribute (line 511) | [DllImport("user32.dll")]
type WindowCompositionAttributeData (line 514) | [StructLayout(LayoutKind.Sequential)]
type WindowCompositionAttribute (line 522) | public enum WindowCompositionAttribute
type AccentState (line 527) | public enum AccentState
type AccentPolicy (line 534) | [StructLayout(LayoutKind.Sequential)]
FILE: RoundedTB/MainWindow.xaml.cs
class MainWindow (line 35) | public partial class MainWindow : Window
type VisiblityControlSet (line 66) | record VisiblityControlSet(WPFUI.Controls.Button KeyControl, IList<Sys...
type VisiblityControlManager (line 68) | record VisiblityControlManager(VisiblityControlSet CenterBar, Visiblit...
method MainWindow (line 93) | public MainWindow()
method UpdateUi (line 382) | public void UpdateUi()
method AutoHide (line 419) | public void AutoHide(bool enabled, List<Types.Taskbar> taskbarDetails)
method TrayIconCheck (line 471) | public void TrayIconCheck(bool isForceReset)
method IsThemeLightMode (line 498) | public bool IsThemeLightMode()
method IsThemeLightModeForWin11 (line 511) | private static bool IsThemeLightModeForWin11()
method ApplyButton_Click (line 521) | public void ApplyButton_Click(object sender, RoutedEventArgs e)
method OnClosing (line 611) | protected override void OnClosing(CancelEventArgs e)
method CloseMenuItem_Click (line 662) | private void CloseMenuItem_Click(object sender, RoutedEventArgs e)
method ShowMenuItem_Click (line 675) | public void ShowMenuItem_Click(object sender, RoutedEventArgs e)
method Startup_Clicked (line 694) | private async void Startup_Clicked(object sender, RoutedEventArgs e)
method EnableStartup (line 715) | public void EnableStartup()
method StartupToggle (line 738) | async Task StartupToggle()
method StartupInit (line 767) | async Task StartupInit(bool clean)
method IsRunningAsUWP (line 830) | public bool IsRunningAsUWP()
method DebugMenuItem_Click (line 844) | private void DebugMenuItem_Click(object sender, RoutedEventArgs e)
method ContextMenu_MouseEnter (line 866) | private async void ContextMenu_MouseEnter(object sender, System.Window...
method dynamicCheckBox_Checked (line 874) | private void dynamicCheckBox_Checked(object sender, RoutedEventArgs e)
method dynamicCheckBox_Unchecked (line 893) | private void dynamicCheckBox_Unchecked(object sender, RoutedEventArgs e)
method cornerRadiusSlider_DragCompleted (line 909) | private void cornerRadiusSlider_DragCompleted(object sender, System.Wi...
method OnSourceInitialized (line 941) | protected override void OnSourceInitialized(EventArgs e)
method splitHelpButton_Click (line 959) | private void splitHelpButton_Click(object sender, RoutedEventArgs e)
method compositionFixCheckBox_Checked (line 968) | private void compositionFixCheckBox_Checked(object sender, RoutedEvent...
method aboutButton_Click (line 981) | private void aboutButton_Click(object sender, RoutedEventArgs e)
method fillMaximisedCheckBox_Checked (line 987) | private void fillMaximisedCheckBox_Checked(object sender, RoutedEventA...
method fillMaximisedCheckBox_Unchecked (line 995) | private void fillMaximisedCheckBox_Unchecked(object sender, RoutedEven...
method showSegmentsOnHoverCheckBox_Checked (line 1002) | private void showSegmentsOnHoverCheckBox_Checked(object sender, Routed...
method showSegmentsOnHoverCheckBox_Unchecked (line 1011) | private void showSegmentsOnHoverCheckBox_Unchecked(object sender, Rout...
method SetLayoutInput (line 1020) | private void SetLayoutInput(Types.SegmentSettings layout)
method taskbarRectStandIn_Click (line 1030) | private void taskbarRectStandIn_Click(object sender, RoutedEventArgs e)
method trayRectStandIn_Click (line 1046) | private void trayRectStandIn_Click(object sender, RoutedEventArgs e)
method widgetsRectStandIn_Click (line 1054) | private void widgetsRectStandIn_Click(object sender, RoutedEventArgs e)
method clockRectStandIn_Click (line 1062) | private void clockRectStandIn_Click(object sender, RoutedEventArgs e)
method mTopInput_LostFocus (line 1070) | private void mTopInput_LostFocus(object sender, RoutedEventArgs e)
method mBottomInput_LostFocus (line 1102) | private void mBottomInput_LostFocus(object sender, RoutedEventArgs e)
method mLeftInput_LostFocus (line 1134) | private void mLeftInput_LostFocus(object sender, RoutedEventArgs e)
method mRightInput_LostFocus (line 1166) | private void mRightInput_LostFocus(object sender, RoutedEventArgs e)
method cornerRadiusInput_LostFocus (line 1198) | private void cornerRadiusInput_LostFocus(object sender, RoutedEventArg...
method cornerRadiusSlider_ValueChanged (line 1232) | private void cornerRadiusSlider_ValueChanged(object sender, RoutedProp...
FILE: RoundedTB/MonitorStuff.cs
class MonitorStuff (line 8) | class MonitorStuff
method EnumDisplayMonitors (line 10) | [DllImport("user32.dll")]
method GetMonitorInfo (line 12) | [DllImport("user32.dll")]
type MONITORINFO (line 15) | [StructLayout(LayoutKind.Sequential)]
type POINT (line 25) | [StructLayout(LayoutKind.Sequential)]
method GetDisplays (line 41) | public static DisplayInfoCollection GetDisplays()
class DisplayInfoCollection (line 72) | public class DisplayInfoCollection : List<DisplayInfo>
class DisplayInfo (line 77) | public class DisplayInfo
FILE: RoundedTB/Properties/Resources.Designer.cs
class Resources (line 22) | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resource...
method Resources (line 31) | [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Mic...
FILE: RoundedTB/Properties/Settings.Designer.cs
class Settings (line 14) | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
FILE: RoundedTB/Taskbar.cs
class Taskbar (line 18) | class Taskbar
method CheckIfCentred (line 26) | public static bool CheckIfCentred()
method TaskbarRefreshRequired (line 65) | public static bool TaskbarRefreshRequired(Types.Taskbar currentTB, Typ...
method GetQuickTaskbarRects (line 119) | public static Types.Taskbar GetQuickTaskbarRects(IntPtr taskbarHwnd, I...
method ResetTaskbar (line 146) | public static void ResetTaskbar(Types.Taskbar taskbar, Types.Settings ...
method UpdateSimpleTaskbar (line 173) | public static bool UpdateSimpleTaskbar(Types.Taskbar taskbar, Types.Se...
method UpdateDynamicTaskbar (line 212) | public static bool UpdateDynamicTaskbar(Types.Taskbar taskbar, Types.S...
method TaskbarCountOrHandleChanged (line 377) | public static bool TaskbarCountOrHandleChanged(int taskbarCount, IntPt...
method CheckDynamicUpdateIsValid (line 421) | public static bool CheckDynamicUpdateIsValid(Types.Taskbar currentTB, ...
method GetAppListSince23H2 (line 467) | public static Types.AppListXaml GetAppListSince23H2(IntPtr hwndTaskbar...
method GenerateTaskbarInfo (line 479) | public static List<Types.Taskbar> GenerateTaskbarInfo(bool isWindows11)
method TaskbarShouldBeFilled (line 594) | public static bool TaskbarShouldBeFilled(IntPtr taskbarHwnd, Types.Set...
method SetTaskbarState (line 642) | public static void SetTaskbarState(LocalPInvoke.AppBarStates option, I...
FILE: RoundedTB/TaskbarEffect.xaml.cs
class TaskbarEffect (line 25) | public partial class TaskbarEffect : Window
method TaskbarEffect (line 31) | public TaskbarEffect()
method backgroundWorker_DoWork (line 54) | private void backgroundWorker_DoWork(object sender, DoWorkEventArgs e)
method MoveTheThingy (line 62) | public void MoveTheThingy()
method GetCursorPos (line 74) | [DllImport("user32.dll")]
type POINT (line 78) | public struct POINT
FILE: RoundedTB/Types.cs
class Types (line 14) | public class Types
class Taskbar (line 16) | public class Taskbar : IDisposable
method Dispose (line 35) | public void Dispose()
class AppListXaml (line 42) | public class AppListXaml : IDisposable
method AppListXaml (line 53) | public AppListXaml(IntPtr hwndTaskbarMain)
method GetTaskbarFrameElement (line 60) | private static IUIAutomationElement? GetTaskbarFrameElement(IntPtr h...
method ReloadTaskbarFrameElement (line 83) | public void ReloadTaskbarFrameElement()
method GetWindowRect (line 94) | public LocalPInvoke.RECT? GetWindowRect()
method Dispose (line 168) | public void Dispose()
class Settings (line 184) | public class Settings
class EffectiveRegion (line 208) | public class EffectiveRegion
class SegmentSettings (line 217) | public class SegmentSettings
type TrayMode (line 226) | public enum TrayMode
type CompositionMode (line 233) | public enum CompositionMode
type KeyModifier (line 240) | public enum KeyModifier
Condensed preview — 39 files, each showing path, character count, and a content snippet. Download the .json file or copy for the full structured content (521K chars).
[
{
"path": ".gitattributes",
"chars": 2518,
"preview": "###############################################################################\n# Set default behavior to automatically "
},
{
"path": ".github/workflows/ci.yml",
"chars": 879,
"preview": "name: release\n\non:\n push:\n\njobs:\n build:\n name: build-windows\n runs-on: windows-2022\n\n steps:\n - name: Che"
},
{
"path": ".gitignore",
"chars": 6252,
"preview": "## Ignore Visual Studio temporary files, build results, and\n## files generated by popular Visual Studio add-ons.\n##\n## G"
},
{
"path": "AnalysisReport.sarif",
"chars": 4808,
"preview": "{\n \"$schema\": \"https://schemastore.azurewebsites.net/schemas/json/sarif-2.1.0-rtm.5.json\",\n \"version\": \"2.1.0\",\n \"run"
},
{
"path": "LICENSE",
"chars": 35149,
"preview": " GNU GENERAL PUBLIC LICENSE\n Version 3, 29 June 2007\n\n Copyright (C) 2007 Free "
},
{
"path": "PackagingProject/Package.appxmanifest",
"chars": 2410,
"preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n\n<Package\n xmlns=\"http://schemas.microsoft.com/appx/manifest/foundation/windows"
},
{
"path": "PackagingProject/RoundedTB.Package.wapproj",
"chars": 9814,
"preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<Project ToolsVersion=\"15.0\" DefaultTargets=\"Build\" xmlns=\"http://schemas.microso"
},
{
"path": "README.md",
"chars": 2261,
"preview": "\n\n# RoundedTB\n####"
},
{
"path": "RoundedTB/.editorconfig",
"chars": 5804,
"preview": "# Rules in this file were initially inferred by Visual Studio IntelliCode from the C:\\Users\\Torch\\source\\repos\\RoundedTB"
},
{
"path": "RoundedTB/AboutWindow.xaml",
"chars": 10691,
"preview": "<Window x:Class=\"RoundedTB.AboutWindow\"\n xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\n "
},
{
"path": "RoundedTB/AboutWindow.xaml.cs",
"chars": 1367,
"preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\nusi"
},
{
"path": "RoundedTB/App.config",
"chars": 178,
"preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<configuration>\n <startup> \n <supportedRuntime version=\"v4.0\" sku=\".NET"
},
{
"path": "RoundedTB/App.xaml",
"chars": 730,
"preview": "<Application x:Class=\"RoundedTB.App\"\n xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\n "
},
{
"path": "RoundedTB/App.xaml.cs",
"chars": 446,
"preview": "using System;\nusing System.Collections.Generic;\nusing System.Configuration;\nusing System.Data;\nusing System.Linq;\nusing"
},
{
"path": "RoundedTB/AppBars.cs",
"chars": 2900,
"preview": "using System;\nusing System.Runtime.InteropServices;\n\nnamespace RoundedTB\n{\n class AppBars\n {\n [DllImport(\""
},
{
"path": "RoundedTB/Background.cs",
"chars": 18633,
"preview": "using System;\nusing System.Collections.Generic;\nusing System.ComponentModel;\nusing System.Diagnostics;\nusing System.Tex"
},
{
"path": "RoundedTB/EnumerableExtensions.cs",
"chars": 396,
"preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\n\nna"
},
{
"path": "RoundedTB/FodyWeavers.xml",
"chars": 137,
"preview": "<Weavers xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xsi:noNamespaceSchemaLocation=\"FodyWeavers.xsd\">\n <Cost"
},
{
"path": "RoundedTB/IAppVisibility.cs",
"chars": 1270,
"preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Runtime.InteropServices;\nusing System.T"
},
{
"path": "RoundedTB/Infobox.xaml",
"chars": 1320,
"preview": "<Window x:Class=\"RoundedTB.Infobox\"\n xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\n x"
},
{
"path": "RoundedTB/Infobox.xaml.cs",
"chars": 701,
"preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\nusi"
},
{
"path": "RoundedTB/Interaction.cs",
"chars": 14141,
"preview": "using Newtonsoft.Json;\nusing System;\nusing System.Collections.Generic;\nusing System.Diagnostics;\nusing System.IO;\nusing"
},
{
"path": "RoundedTB/LocalPInvoke.cs",
"chars": 21984,
"preview": "using System;\nusing System.Diagnostics;\nusing System.Runtime.InteropServices;\nusing System.Text;\n\nnamespace RoundedTB\n{"
},
{
"path": "RoundedTB/MainWindow.xaml",
"chars": 10679,
"preview": "<Window x:Class=\"RoundedTB.MainWindow\"\n xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\n "
},
{
"path": "RoundedTB/MainWindow.xaml.cs",
"chars": 48954,
"preview": "using IWshRuntimeLibrary;\nusing Newtonsoft.Json;\nusing System;\nusing System.Collections.Generic;\nusing System.Component"
},
{
"path": "RoundedTB/MonitorStuff.cs",
"chars": 3367,
"preview": "using System;\nusing System.Collections.Generic;\nusing System.Runtime.InteropServices;\nusing System.Windows;\n\nnamespace "
},
{
"path": "RoundedTB/Properties/AssemblyInfo.cs",
"chars": 2366,
"preview": "using System.Reflection;\nusing System.Resources;\nusing System.Runtime.CompilerServices;\nusing System.Runtime.InteropSer"
},
{
"path": "RoundedTB/Properties/Resources.Designer.cs",
"chars": 2790,
"preview": "//------------------------------------------------------------------------------\n// <auto-generated>\n// This code w"
},
{
"path": "RoundedTB/Properties/Resources.resx",
"chars": 5494,
"preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<root>\n <!-- \n Microsoft ResX Schema \n \n Version 2.0\n \n The prim"
},
{
"path": "RoundedTB/Properties/Settings.Designer.cs",
"chars": 1064,
"preview": "//------------------------------------------------------------------------------\n// <auto-generated>\n// This code w"
},
{
"path": "RoundedTB/Properties/Settings.settings",
"chars": 193,
"preview": "<?xml version='1.0' encoding='utf-8'?>\n<SettingsFile xmlns=\"uri:settings\" CurrentProfile=\"(Default)\">\n <Profiles>\n "
},
{
"path": "RoundedTB/RoundedTB.csproj",
"chars": 4163,
"preview": "<Project Sdk=\"Microsoft.NET.Sdk\">\n <PropertyGroup>\n <TargetFramework>net6.0-windows10.0.19041</TargetFramework>\n "
},
{
"path": "RoundedTB/Taskbar.cs",
"chars": 30768,
"preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\nusi"
},
{
"path": "RoundedTB/TaskbarEffect.xaml",
"chars": 1037,
"preview": "<Window x:Class=\"RoundedTB.TaskbarEffect\"\n xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\n "
},
{
"path": "RoundedTB/TaskbarEffect.xaml.cs",
"chars": 2380,
"preview": "using System;\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text;\nusing System.Threading.Tasks;\nusi"
},
{
"path": "RoundedTB/Types.cs",
"chars": 9886,
"preview": "using System;\nusing System.Collections.Generic;\nusing System.Drawing;\nusing System.Linq;\nusing System.Runtime.InteropSe"
},
{
"path": "RoundedTB/app.manifest",
"chars": 3660,
"preview": "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<assembly manifestVersion=\"1.0\" xmlns=\"urn:schemas-microsoft-com:asm.v1\" xmlns:a"
},
{
"path": "RoundedTB.sln",
"chars": 3832,
"preview": "\nMicrosoft Visual Studio Solution File, Format Version 12.00\n# Visual Studio Version 17\nVisualStudioVersion = 17.0.3142"
},
{
"path": "upgrade-assistant.clef",
"chars": 216370,
"preview": "{\"@t\":\"2022-01-30T04:07:25.0356602Z\",\"@mt\":\"Hosting starting\",\"@l\":\"Debug\",\"EventId\":{\"Id\":1,\"Name\":\"Starting\"},\"SourceC"
}
]
About this extraction
This page contains the full source code of the Gniang/RoundedTB GitHub repository, extracted and formatted as plain text for AI agents and large language models (LLMs). The extraction includes 39 files (480.3 KB), approximately 123.8k tokens, and a symbol index with 206 extracted functions, classes, methods, constants, and types. Use this with OpenClaw, Claude, ChatGPT, Cursor, Windsurf, or any other AI tool that accepts text input. You can copy the full output to your clipboard or download it as a .txt file.
Extracted by GitExtract — free GitHub repo to text converter for AI. Built by Nikandr Surkov.