Click here to Skip to main content
15,867,686 members
Home / Discussions / C#
   

C#

 
QuestionRe: IDN Awareness Raising answers getting tagged as "Spam". Why? Pin
Eddy Vluggen20-Aug-22 12:30
professionalEddy Vluggen20-Aug-22 12:30 
AnswerRe: IDN Awareness Raising answers getting tagged as "Spam". Why? Pin
Akshat J21-Aug-22 18:20
Akshat J21-Aug-22 18:20 
GeneralRe: IDN Awareness Raising answers getting tagged as "Spam". Why? Pin
Eddy Vluggen22-Aug-22 8:47
professionalEddy Vluggen22-Aug-22 8:47 
Questionhow draw border on round image png? Pin
Le@rner15-Aug-22 19:47
Le@rner15-Aug-22 19:47 
AnswerRe: how draw border on round image png? Pin
Pete O'Hanlon15-Aug-22 20:10
subeditorPete O'Hanlon15-Aug-22 20:10 
GeneralRe: how draw border on round image png? Pin
Le@rner15-Aug-22 20:33
Le@rner15-Aug-22 20:33 
GeneralRe: how draw border on round image png? Pin
Richard MacCutchan15-Aug-22 21:33
mveRichard MacCutchan15-Aug-22 21:33 
GeneralRe: how draw border on round image png? Pin
Le@rner15-Aug-22 21:38
Le@rner15-Aug-22 21:38 
Bitmap bmp = new Bitmap(@"C:\Users\Ali\Desktop\1.png");
            int w = bmp.Width;
            int h = bmp.Height;
            Lst_Data lastpointcolor = new Lst_Data() ;
            for (int y = 0; y < h; y++)
            {
                for (int x = 0; x < w; x++)
                {
                    Color c = bmp.GetPixel(x, y);
                    if (c.A != Color.Transparent.A)
                    {
                        if (lastpointcolor.color.A == Color.Transparent.A)
                        {
                            bmp.SetPixel(lastpointcolor.point.X, lastpointcolor.point.Y, Color.Red);
                        }
                    }
                    lastpointcolor = new Lst_Data() { point = new Point(x, y), color = bmp.GetPixel(x, y) };
                }
            }

            for (int y = h-1; y > 0; y--)
            {
                for (int x = w-1; x > 0; x--)
                {
                    Color c = bmp.GetPixel(x, y);
                    if (c.A != Color.Transparent.A)
                    {
                        if (lastpointcolor.color.A == Color.Transparent.A)
                        {
                            bmp.SetPixel(lastpointcolor.point.X, lastpointcolor.point.Y, Color.Red);
                        }
                    }
                    lastpointcolor = new Lst_Data() { point = new Point(x, y), color = bmp.GetPixel(x, y) };
                }
            }
            pictureBox1.Image = bmp;
        }

 public struct Lst_Data
    {
        public Point point;
        public Color color;
    }


can anybody help to draw more thick border around the image
GeneralRe: how draw border on round image png? Pin
Richard MacCutchan15-Aug-22 22:13
mveRichard MacCutchan15-Aug-22 22:13 
AnswerRe: how draw border on round image png? Pin
Gerry Schmitz16-Aug-22 9:57
mveGerry Schmitz16-Aug-22 9:57 
Question.NET and c# windows form app Pin
Баярдаваа Ихтамир8-Aug-22 22:01
Баярдаваа Ихтамир8-Aug-22 22:01 
AnswerRe: .NET and c# windows form app Pin
Richard Deeming8-Aug-22 22:42
mveRichard Deeming8-Aug-22 22:42 
AnswerRe: .NET and c# windows form app Pin
OriginalGriff9-Aug-22 0:36
mveOriginalGriff9-Aug-22 0:36 
AnswerRe: .NET and c# windows form app Pin
Gerry Schmitz9-Aug-22 9:19
mveGerry Schmitz9-Aug-22 9:19 
QuestionDecoding GBK, .NET 6 edition Pin
harold aptroot8-Aug-22 12:07
harold aptroot8-Aug-22 12:07 
AnswerRe: Decoding GBK, .NET 6 edition Pin
lmoelleb8-Aug-22 22:02
lmoelleb8-Aug-22 22:02 
GeneralRe: Decoding GBK, .NET 6 edition Pin
lmoelleb8-Aug-22 23:22
lmoelleb8-Aug-22 23:22 
AnswerRe: Decoding GBK, .NET 6 edition Pin
Richard Deeming8-Aug-22 22:34
mveRichard Deeming8-Aug-22 22:34 
GeneralRe: Decoding GBK, .NET 6 edition Pin
harold aptroot9-Aug-22 4:44
harold aptroot9-Aug-22 4:44 
QuestionHow to close FileStream without causing an error in PdfViewer Pin
Code4Ever7-Aug-22 20:02
Code4Ever7-Aug-22 20:02 
AnswerRe: How to close FileStream without causing an error in PdfViewer Pin
OriginalGriff7-Aug-22 20:25
mveOriginalGriff7-Aug-22 20:25 
GeneralRe: How to close FileStream without causing an error in PdfViewer Pin
Code4Ever7-Aug-22 20:38
Code4Ever7-Aug-22 20:38 
GeneralRe: How to close FileStream without causing an error in PdfViewer Pin
OriginalGriff7-Aug-22 21:16
mveOriginalGriff7-Aug-22 21:16 
GeneralRe: How to close FileStream without causing an error in PdfViewer Pin
OriginalGriff7-Aug-22 21:59
mveOriginalGriff7-Aug-22 21:59 
AnswerRe: How to close FileStream without causing an error in PdfViewer Pin
Richard Deeming8-Aug-22 0:08
mveRichard Deeming8-Aug-22 0:08 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.