A Project Report: "Paint Application
A Project Report: "Paint Application
A Project Report: "Paint Application
PROJECT REPORT
ON
“Paint Application”
DIPLOMA IN
COMPUTER ENGINEERING
SUBMITTED TO
MAHARASHTRA STATE BOARD OF TECHNICAL EDUCATION,
MUMBAI
SUBMITTED BY
GUIDED BY
(Prof.Pokharkar.M.S)
CERTIFICATE
This is to certify that the project report entitled “Paint Application” Was
successfully completed by Student of Fifth semester Diploma in computer
engineering.
3)Tambe Priyanka
in partial fulfillment of the requirements for the award of the Diploma in
Computer engineering and submitted to the Department of Computer of
Samarth Polytechnic, Belhe work carried out during a period for the academic
year 2020- 21 as per curriculum.
This project is done as a semester project, as a part course titled “Waste Management ”.
We are really thankful to our course the Principal Prof. Kapile A. S. and the HOD Prof.
Pokharkar M.S. Samarth Polytechnic, Belhe for his invaluable guidance and assistance,
without which the accomplishment of the task would have never been possible. We also
thank Prof. Pokharkar M.S. for giving this opportunity to explore into the real world and
realize the interrelation without which a Project can never progress. In our present project
we have chosen the topic- “Paint Application”. We are also thankful to parents, friend
and all staff of Computer engineering department, for providing us relevant information
and necessary clarifications, and great support.
1)Thite Purva
2)Varhadi Vaishnavi
3)Tambe Priyanka
INDEX
Sr.No. Name of Chapter Page No.
Chapter 1 Synopsis
1.1 Project Title
Chapter 2 Abstract 2
Chapter 4 Introduction 4
Chapter 9 Conclusion 13
Chapter 10 Reference 14
Paint Application
CHAPTER 1
SYNOPSIS
CHAPTER 2
Abstract
Writing graphics applications in Java using Swing can be quite a daunting experience which requires
understanding of some large libraries, and fairly advanced aspects of Java. In a graphical system, a windowing
toolkit is usually responsible for providing a framework to make it relatively painless for a graphical user interface
(GUI) to render the right bits to the screen at the right time. Both the AWT (abstract windowing toolkit) and
Swing provide such a framework. In this report, we designed and developed a simple painter project used to
enable user to draw any shape and any integrated graphic with any color using FreeHand (move the mouse using
your hand to draw any shape and specify the coordinate in JPanel). Several tools such as Undo and Redo process,
Clear JPanel, Set Background Color & set Foreground Color, Save paint (Panel) to file ( *. JPG; *. GIF; *.* ), and
Open paint from image file are considered. The purpose of this project is to give you practice with graphical user
interface programming in Java. This project implemented using the components from Java's awt and swing library
in the Java programming language (NetBenas IDE7.2.1). As the final result of our project is enabling you to use
Free Hand to draw as an easy way to draw the Circle, Line, Rectangle, Square, and Oval , and integrated graphics
such as a car , a street , a football stadium , traffic signals and others.
CHAPTER 3
Hardware Requirement:
Software Requirement:
i. Windows 7
ii. Microsoft Word
iii. Internet
CHAPTER 4
INTRODUCTION
The history of painting reaches back in time to artefacts from pre-historic humans, and spans all
cultures. It represents a continuous, though periodically disrupted, tradition from Antiquity. Across
cultures, and spanning continents and millennia, the history of painting is an ongoing river of creativity,
that continues into the 21st century. Until the early 20th century it relied primarily on representational,
religious and classical motifs, after which time more purely abstract and conceptual approaches gained
favour.
Developments in Eastern painting historically parallel those in Western painting, in general, a few
centuries earlier. African art, Jewish art, Islamic art, Indian art, Chinese art, and Japanese art each had
significant influence on Western art, and vice versa.
Initially serving utilitarian purpose, followed by imperial, private, civic, and religious
patronage, Eastern and Western painting later found audiences in the aristocracy and the middle class.
From the Modern era, the Middle Ages through the Renaissance painters worked for the church and a
wealthy aristocracy. Beginning with the Baroque era artists received private commissions from a more
educated and prosperous middle class. Finally in the West the idea of "art for art's sake" began to find
expression in the work of the Romantic painters like Francisco de Goya, John Constable, and J. M. W.
Turner. The 19th century saw the rise of the commercial art gallery, which provided patronage in the
20th century.
CHAPTER 5
drawPad.clear();
}
});
//this is the clear button, which clears the screen. This pretty
//much attaches an action listener to the button and when the
//button is pressed it calls the clear() method
JButton redButton = new JButton(iconR);
//creates the red button and sets the icon we created for red
redButton.addActionListener(new ActionListener()
{
public void actionPerformed(ActionEvent e)
{
drawPad.red();
}
});
//when pressed it will call the red() method. So on and so on =]
JButton blackButton = new JButton(iconBl);
//same thing except this is the black button
blackButton.addActionListener(new ActionListener()
{
public void actionPerformed(ActionEvent e)
{
drawPad.black();
}
});
JButton magentaButton = new JButton(iconM);
//magenta button
magentaButton.addActionListener(new ActionListener()
{
public void actionPerformed(ActionEvent e)
{
drawPad.magenta();
}
});
JButton blueButton = new JButton(iconB);
//blue button
blueButton.addActionListener(new ActionListener()
{
public void actionPerformed(ActionEvent e)
{
drawPad.blue();
}
});
JButton greenButton = new JButton(iconG);
//green button
greenButton.addActionListener(new ActionListener()
{
});
//if the mouse is pressed it sets the oldX & oldY
//coordinates as the mouses x & y coordinates
addMouseMotionListener(new MouseMotionAdapter()
{
public void mouseDragged(MouseEvent e)
{
currentX = e.getX();
currentY = e.getY();
if(graphics2D != null)
graphics2D.drawLine(oldX, oldY, currentX, currentY);
repaint();
oldX = currentX;
oldY = currentY;
}
});
//while the mouse is dragged it sets currentX & currentY as the mouses
x and y
//then it draws a line at the coordinates
//it repaints it and sets oldX and oldY as currentX and currentY
}
public void paintComponent(Graphics g)
{
if(image == null)
{
image = createImage(getSize().width, getSize().height);
graphics2D = (Graphics2D)image.getGraphics();
graphics2D.setRenderingHint(RenderingHints.KEY_ANTIALIASING,
RenderingHints.VALUE_ANTIALIAS_ON);
clear();
}
g.drawImage(image, 0, 0, null);
}
//this is the painting bit
//if it has nothing on it then
//it creates an image the size of the window
//sets the value of Graphics as the image
//sets the rendering
//runs the clear() method
//then it draws the image
public void clear()
{
graphics2D.setPaint(Color.white);
graphics2D.fillRect(0, 0, getSize().width, getSize().height);
graphics2D.setPaint(Color.black);
repaint();
}
CHAPTER 6
Outcome of Micro-Project
CHAPTER 7
CH
APTER 8
CHAPTER 9
CONCLUSION
This report presents an introduction to Java and how Java is used to build graphics and what are
the tools that can be used to develop graphics and drawing required shapes.
This was an introduction to the main goal of our report that presented that is design and
development a simple Painter project used to draw any shape (Circle, Line, Rectangle, Square,
and Oval using FreeHand, Undo and Redo process, Clear JPanel, Set Background Color & set
Foreground Color, Save paint (Panel) to file ( *. JPG; *. GIF; *.* ), and Open paint from image
file are considered. The system enables you to use Free Hand to draw as an easy way to draw the
integrated paint, for example, a car , a street , traffic signals and others.
REFERENCE
https://www.javatpoint.com/java-tutorial
https://en.wikipedia.org/wiki/
Java_(programming_language)
https://www.w3schools.com/java/java_intro.asp
We have chosen this micro project to get knowledge about waste management.
4.0 ActionPlan
Resources Required
******************
ANNEXURE II
Evaluation Sheet for Micro Project
Academic Year:-2020-21 Name of Faculty :- Prof. Pokharkar M.S. Course:-AJP
a) Practical Outcomes………………………………………………………………………………………..
………………………………………………………………………………………………………………….b) Unit Outcomes in Cognitive
domain…………………………………………………………………..
…………………………………………………………………………….
………………………...................................................................................................................................
............
……………………………………………………………………………………………………
c)Outcomes in Afffective
Domain………………………………………………………………………………………………………………………………………
……………………………………………………………………………………………………………………………………………………
………….
Mrs.Shelke N.S.