Unable to save graphics.h

Jul 1, 2014 at 1:30am
I have downloaded graphics.h from http://winbgim.codecutter.org/ following the instructions from http://rekursed.blogspot.com/2012/03/how-to-include-graphicsh-in-codeblocks.html and i got the following error when trying to compile the graphics program:
1
2
   redefinition of int right
   int right was already declared

because of the following code
 
    int left=0, int right=0, int right=INT_MAX, int bottom=INT_MAX

so i changed the first right to to top as specified in http://rekursed.blogspot.com/2012/03/how-to-include-graphicsh-in-codeblocks.html like so
 
    int left = 0, int top=0,int right=INT_MAX, int bottom=INT_MAX

but i recieve the following error
 
    <graphics.h directory> cannot be saved

so i cannot edit the file to fix it. If someone may help me fix this problem. In http://rekursed.blogspot.com/2012/03/how-to-include-graphicsh-in-codeblocks.html, a person specified fixing it with a text editor if that helps. Also let me know if i have posted this in the wrong forum, please tell me so that i may be able to fix this problem. Thank you.
Jul 1, 2014 at 1:57am
the best solution is to not use graphics.h
Jul 1, 2014 at 3:06am
Yeah, the best solution is to not use it. I'm guessing you're right about the first being int top = 0 though.
1
2
3
4
5
6
void printimage(
    const char* title=NULL,	
    double width_inches=7, double border_left_inches=0.75, double border_top_inches=0.75,
    int left=0, int right=0, int right=INT_MAX, int bottom=INT_MAX,
    bool active=true, HWND hwnd=NULL
    );
Last edited on Jul 1, 2014 at 3:08am
Topic archived. No new replies allowed.