Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. Graphics Class

Graphics Class

Scheduled Pinned Locked Moved C#
graphicsquestion
4 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    Amir Jalaly
    wrote on last edited by
    #1

    Hi i work with System.Drawing.Graphic class . i want to save the variable to an image object and then restore the image to variable of graphic class . and another question : how can get the color of pixel in form ? have i must use the graphic class ? 2-when i draw a line in form and minimize the form after resoring form line is cleared . what i must do to save the contant of form ? Regards Amir Jalaly

    D M 2 Replies Last reply
    0
    • A Amir Jalaly

      Hi i work with System.Drawing.Graphic class . i want to save the variable to an image object and then restore the image to variable of graphic class . and another question : how can get the color of pixel in form ? have i must use the graphic class ? 2-when i draw a line in form and minimize the form after resoring form line is cleared . what i must do to save the contant of form ? Regards Amir Jalaly

      D Offline
      D Offline
      Dave Kreskowiak
      wrote on last edited by
      #2

      Amir Jalaly wrote: i want to save the variable to an image object and then restore the image to variable of graphic class WHAT?? This makes no sense what-so-ever. The Graphics class doesn't represent an image of anything. Perhaps a better explanation of what you want to accomplish would help. Amir Jalaly wrote: when i draw a line in form and minimize the form after resoring form line is cleared . All your drawing on the form surface must be done in the Form's OnPaint event. You have to repaint your graphic items every time the form is redrawn, which happens quite frequently. RageInTheMachine9532 "...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome

      1 Reply Last reply
      0
      • A Amir Jalaly

        Hi i work with System.Drawing.Graphic class . i want to save the variable to an image object and then restore the image to variable of graphic class . and another question : how can get the color of pixel in form ? have i must use the graphic class ? 2-when i draw a line in form and minimize the form after resoring form line is cleared . what i must do to save the contant of form ? Regards Amir Jalaly

        M Offline
        M Offline
        Muhammad Gulzaib Khan
        wrote on last edited by
        #3

        hi dear me too is working on these images and graphics ans: Q2:- Register the event handler of OnPaint to save the color of pixel use Getpixel(), it returns a Color object u can use it later. Graphics class surely helps. Abt Q1 i can't understand what have u asked plz ellaborate it

        A 1 Reply Last reply
        0
        • M Muhammad Gulzaib Khan

          hi dear me too is working on these images and graphics ans: Q2:- Register the event handler of OnPaint to save the color of pixel use Getpixel(), it returns a Color object u can use it later. Graphics class surely helps. Abt Q1 i can't understand what have u asked plz ellaborate it

          A Offline
          A Offline
          Amir Jalaly
          wrote on last edited by
          #4

          HI Thanks for your answer . i don't understand how i must use GetPixel . is that a func of graphic class ? Can you help me more ? Also i want to fill a area that i draw in my form . can help me plz ? Regards Amir Jalaly

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups