'system.Drawing vs Maui.Graphics; From.Argb gives different output

So I am using .NET Maui and came across the following problem. I want to use .FromArgb but in Maui. Originally I was using System.Drawing.Color, but using Maui. Graphics.Color gives a different result:

//Color (example color)
int KeyColor = -16777088;

//system.Drawing way:
var forgroundColor = System.Drawing.Color.FromArgb(KeyColor);
//Output: "{Name=ff000080, ARGB=(255, 0, 0, 128)}"

//Maui.Graphics way (I have to use ToString cuz FromArgb needs an string):
var forgroundColorMaui = Microsoft.Maui.Graphics.Color.FromArgb(KeyColor.ToString());
//Output: Red=0, Green=0, Blue=0, Alpha=1

So I want to use the output from system.drawing but then in the Maui.Graphics. I dont know why the outputs are different. Anyone got an idea? Thanks you!



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source