Your SEO optimized title
HOW TO ADD Graphics IN TURBO C++
Graphics are basically the main requirement of any software bcz it become software user friendly
sample graphics program in dev c++
BY Adding Graphics The programs become Graphicaly user friendly and Every Person Easily Understand The Working Of Software
Graphics in C++ tutorials
In turboo c++ it is some difficulty to add the graphics bcz it is directly not proper work therefore First of All We open C disk then we open the turbo++ Then We Open Disk After this We Open The BGI folder Now We Copy all Files Of BGi folder And then paste all files to BIN Now Graphics Properly Link With Turboo c++ And After this you can easily work on graphics And Add Graphics To your software Or Programs
HOW TO Intialize Graphics in Turboo c++
First of All We Add The Graphics.h headrel File In the Programs
Graphics.h
Then We intialize the Graphics Driver As
int gdriver=DETECT,gmod;
then we initialize the graphics as
initgraph(&gdriver,&gmod," ");
After this whatever you want to do with graphics in programm you can do like as draw the line ,draw the circle ,draw the 3d bar .etc;
After Doing Work with Graphics It is must that close the Graphics same as intialize the Graphics Now we can close graphics as
closegraph();
SYNTAX OF GRAPHICS IN TURBOO C++
Int gdriver=DETECT,gmod;
initgraph(&gdriver,&gmod,"");
closegraph();
This is the syntax of graphics used in turboo c++
Example of Graphics
#include<iostream.h>
#include<conio.h>
#include<graphics.h>
#include<stdio.h>
void main()
{
int gdriver=DETECT,gmod;
initgraph(&gdriver,&gmod,"");
clrscr();
setcolor(4);
settextstyle(4,0,5);
settextjustify(LEFT_TEXT,RIGHT_TEXT);
outtextxy(40,3,"Ticket Management System");
settextstyle(7,0,3);
settextjustify(LEFT_TEXT,RIGHT_TEXT);
outtextxy(145,80,"1:-For New Passenger");
settextstyle(7,0,3);
settextjustify(LEFT_TEXT,RIGHT_TEXT);
outtextxy(145,110,"2:-Display All Passenger");
outtextxy(145,140,"3:-Search By Ticket ID");
outtextxy(145,170,"4:-Search ByName Passenger");
outtextxy(145,170,"4:-Delete Ticket");
outtextxy(145,200,"5:-Exit");
rectangle(40,65,550,300);
closegraph();
}
Let,s Try Your Own Compiler
Best of Luck!!!!
settextstyle(4,0,5);
settextjustify(LEFT_TEXT,RIGHT_TEXT);
outtextxy(40,3,"Ticket Management System");
settextstyle(7,0,3);
settextjustify(LEFT_TEXT,RIGHT_TEXT);
outtextxy(145,80,"1:-For New Passenger");
settextstyle(7,0,3);
settextjustify(LEFT_TEXT,RIGHT_TEXT);
outtextxy(145,110,"2:-Display All Passenger");
outtextxy(145,140,"3:-Search By Ticket ID");
outtextxy(145,170,"4:-Search ByName Passenger");
outtextxy(145,170,"4:-Delete Ticket");
outtextxy(145,200,"5:-Exit");
rectangle(40,65,550,300);
closegraph();
}
Let,s Try Your Own Compiler
Best of Luck!!!!

No comments:
Post a Comment