0% found this document useful (0 votes)
44 views

Oopm Mini

This document is a project report submitted by students Mohd Faraaz Sarguru, Amaan Siddique, and Pranav Singh for their degree in Bachelor of Engineering in Computer Engineering. It describes the development of a text editor application using Java and IntelliJ. The application allows editing plain text files and includes basic features like changing font size and color. It discusses the objectives, existing limitations, proposed system architecture, algorithm, hardware and software requirements, and includes code snippets of the program. The project was implemented to create a simple yet customizable text editor.

Uploaded by

Ajit Sargar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
44 views

Oopm Mini

This document is a project report submitted by students Mohd Faraaz Sarguru, Amaan Siddique, and Pranav Singh for their degree in Bachelor of Engineering in Computer Engineering. It describes the development of a text editor application using Java and IntelliJ. The application allows editing plain text files and includes basic features like changing font size and color. It discusses the objectives, existing limitations, proposed system architecture, algorithm, hardware and software requirements, and includes code snippets of the program. The project was implemented to create a simple yet customizable text editor.

Uploaded by

Ajit Sargar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 20

Excelssior Education Society’s

K.C.College Of Engineering and Management Studies and Research


(Affiliated to the University of Mumbai)
MithBunder Road, Near Hume Pipe, Kopri, Thane (E)-400603

“TEXT EDITOR”

Submitted in partial fulfillment of the requirements of the degree


BACHELOR OF ENGINEERING IN COMPUTER
ENGINEERING

By

Mohd Faraaz Sarguru (18)


Amaan Siddique (28)
Pranav Singh (31)

Supervisor
Prof.
Department of Computer Engineering
K.C. College of Engineering and Management Studies and Research
MithBunder Road, Kopri, Thane (E)-400603
University of Mumbai
(AY 2021-22)

CERTIFICATE

This is to certify that the Mini Project entitled “TEXT EDITOR” is a bonafide work of

Mohd Faraaz (18) , Amaan Siddique (28) , Pranav Singh (31) submitted to the University

of Mumbai inpartial fulfillment of the requirement for the award of the degree of “Bachelor of

Engineering” in SE “ComputerEngineering”.

Supervisor
Prof.

Head of The Department Principal


Prof. Mandar Ganjapurkar Dr. Vilas Nitnaware
Mini Project Approval

This Mini Project entitled “TEXT EDITOTR” by Mohd Faraaz (18) , Amaan

Siddique (28) , Pranav Singh (31) is approved for the degree of Bachelor of

Engineering in Computer Engineering.

Examiners

1………………………………………
(Internal Examiner Name & Sign)

2…………………………………………
(External Examiner name & Sign)

Date:

Place:
Contents

Abstract ii

Acknowledgments iii

List of Abbreviations iv

List of Figures v

List of Tables vi

List of Symbols vii

1 Introduction 1
1.1 Introduction
1.2 Motivation
1.3 Problem Statement &Objectives
1.4 Organization of the Report

2 Literature Survey 11

2.1 Survey of Existing System


2.2 Limitation Existing system or research gap
2.3 Mini Project Contribution

3 Proposed System(eg NewApproach of Data Summarization ) 18

3.1 Introduction
3.2 Architecture/Framework
3.3 Algorithm and Process Design
3.4 Details of Hardware & Software
3.4 Experiment and Results
3.5 Conclusion and Futurework.

References 32
ABSTRACT

We have Developed a Text Editor using IntelliJ in Java. It exhibits the


basic functionalities which any text editor should have but we have
personalized

IntelliJ was chosen because any editor requires a good graphical interface
and IntelliJ provides that.

The functions incorporated needed accurate syntax for proper functioning


and this was done by Java.

Our next challenge was to know all syntaxes and put them in proper
places in the source code.
ACKNOWLEDGMENT

The satisfaction that accompanies that the successful completion of


any task would be incomplete without the mention of people whose
ceaseless cooperation made it possible, whose constant guidance and
encouragement crown all efforts with success.

I wish to express my sincere gratitude to Prof.Mandar Ganjapurkar


for providing me an opportunity to do my miniproject .

I also wish to express my gratitude to the other staff members who


rendered their help during the period and providing me the chance to
embark on this project.
INTRODUCTION
Text Editor is software that edits plain text and comprises of Java
IntelliJ. This project has all the frames prepared in IntelliJ.

The Java Editors Explains:


 Demonstrates the standard features available for
custom text editors.
 Shows how to register an editor for a file extensions (in
this case .java) and How to define a custom document
provider for used by that editor. only for demonstration
purpose
 Java editing support is required by the IntelliJ Java
tooling.
OBJECTIVES

A text editor refers to any form of computer program that enables


users to create, change, edit, open and view plain text files. Tex
editors are mostly used for text editors review making text more
attractive easy to read. Basic features of a text editor include the
ability to cut, paste and copy text, find and replace words or
characters, create bulleted lists, line-wrap text, and undo or redo a
last command. They’re also equipped to open very large files (too
big for a computer’s main memory to process) and read them at
speed.
Limitation Existing system or research gap

With many advantages, there are always some limitations present.


These are some of them:

➢ Text files used by Notepad should be not larger than 45 kb. Notepad
 Cannot open a file that exceeds 54 kb inside.
 And does not allow you to continue editing a fire with fire size reaches
between 45 kb and 54 kb.
 Sometimes it cannot be made attractive.
 And it does not have backup facility.
 Sometimes it cannot edit complex code.

➢ It also doesn’t have default templates to make your web design


quicker. It

➢ The main disadvantage of Notepad is that it is a very simple software


and
it’s primary function is not for HTML.
➢ You also have to preview in a Web browser which
PROPOSED SYSTEM( eg NewApproach of
Data Summarization)

The proposed system has been evolved. This project aims to


makes it easier for programmers to build custom software
applications by highlighting the Java code both syntactically
and semantically.
It is helpful in following ways:

 First of all, it is object oriented.


 It is platform independent.
 And also portable and stable.
 Also Simple and Easy to understand.
ARCHITECTURE AND FRAMEWORK

1) It allows user to edit any text in this text editor program.


2) It does not requires any specific details to run the program.
3) To increase efficiency of neat and better understanding
text.
4) Editing, adding and updating of records is improved which
results in proper resource of text editing.
5) this application is free for user which does not affect user's
cost user.
6) Only need a smartphone or tablet which has Android OS to
the work.
ALGORITHM AND PROCESS DESIGN

First, user should open the program:


 Type your text.
 Change the font.
 Change the dimensions.
 Can also change the Colours.

DETAILS OF HARDWARE AND SOFTWARE


Hardware requirements
Ram:- 2GB
Processor:- intel core i3
Software requirements
Operating system:- Windows-7
Front design:- IntelliJ
Front End language:- Java
Back end language:- MySQL

Functional requirements
Text Editor involves the
following functions: -
• Easy to edit any text.
• Content look more attractive and easy to read.

CONCLUSION
Application was deployed successfully in a Android
device or software system like laptop and it gives
good results as per expectations. Project can be
implemented for editing any text anywhere using
laptops. Using this system, paper work which is done
can be made more colourful, more attractive and easy
to understand.

FUTUREWORK

Java Text Editor is to be designed as per any user’s


perspective .
By implementing it, user’s can access it anywhere
anytime which will be reduce manual work for the
working of user’s in Offices.
PROGRAM
package JavaTextEditor;

import java.awt.*;
import java.awt.event.*;
import java.io.*;
import java.util.*;
import javax.swing.*;
import javax.swing.event.*;
import javax.swing.filechooser.*;

public class TextEditor extends JFrame implements ActionListener{

JTextArea textArea;
JScrollPane scrollPane;
JLabel fontLabel;
JSpinner fontSizeSpinner;
JButton fontColorButton;
JComboBox fontBox;

JMenuBar menuBar;
JMenu fileMenu;
JMenuItem openItem;
JMenuItem saveItem;
JMenuItem exitItem;

TextEditor(){
this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
this.setTitle("SE-IT Java TextEditor");
this.setSize(500, 500);
this.setLayout(new FlowLayout());
this.setLocationRelativeTo(null);

textArea = new JTextArea();


textArea.setLineWrap(true);
textArea.setWrapStyleWord(true);
textArea.setFont(new Font("Arial",Font.PLAIN,20));

scrollPane = new JScrollPane(textArea);


scrollPane.setPreferredSize(new Dimension(450,450));
scrollPane.setVerticalScrollBarPolicy(ScrollPaneConstants.VERTICAL_SCROLLBAR_ALWAYS);

fontLabel = new JLabel("Font: ");


fontSizeSpinner = new JSpinner();
fontSizeSpinner.setPreferredSize(new Dimension(50,25));
fontSizeSpinner.setValue(20);
fontSizeSpinner.addChangeListener(new ChangeListener() {

@Override
public void stateChanged(ChangeEvent e) {

textArea.setFont(new Font(textArea.getFont().getFamily(),Font.PLAIN,(int) fontSizeSpinner.getValue()));


}

});

fontColorButton = new JButton("Color");


fontColorButton.addActionListener(this);

String[] fonts = GraphicsEnvironment.getLocalGraphicsEnvironment().getAvailableFontFamilyNames();

fontBox = new JComboBox(fonts);


fontBox.addActionListener(this);
fontBox.setSelectedItem("Arial");

// ------ menubar ------

menuBar = new JMenuBar();


fileMenu = new JMenu("File");
openItem = new JMenuItem("Open");
saveItem = new JMenuItem("Save");
exitItem = new JMenuItem("Exit");

openItem.addActionListener(this);
saveItem.addActionListener(this);
exitItem.addActionListener(this);

fileMenu.add(openItem);
fileMenu.add(saveItem);
fileMenu.add(exitItem);
menuBar.add(fileMenu);

// ------ /menubar ------

this.setJMenuBar(menuBar);
this.add(fontLabel);
this.add(fontSizeSpinner);
this.add(fontColorButton);
this.add(fontBox);
this.add(scrollPane);
this.setVisible(true);
}

@Override
public void actionPerformed(ActionEvent e) {

if(e.getSource()==fontColorButton) {
JColorChooser colorChooser = new JColorChooser();
Color color = colorChooser.showDialog(null, "Choose a color", Color.black);

textArea.setForeground(color);
}

if(e.getSource()==fontBox) {
textArea.setFont(new Font((String)fontBox.getSelectedItem(),Font.PLAIN,textArea.getFont().getSize()));
}

if(e.getSource()==openItem) {
JFileChooser fileChooser = new JFileChooser();
fileChooser.setCurrentDirectory(new File("."));
FileNameExtensionFilter filter = new FileNameExtensionFilter("Text files", "txt");
fileChooser.setFileFilter(filter);

int response = fileChooser.showOpenDialog(null);

if(response == JFileChooser.APPROVE_OPTION) {
File file = new File(fileChooser.getSelectedFile().getAbsolutePath());
Scanner fileIn = null;

try {
fileIn = new Scanner(file);
if(file.isFile()) {
while(fileIn.hasNextLine()) {
String line = fileIn.nextLine()+"\n";
textArea.append(line);
}
}
} catch (FileNotFoundException e1) {
// TODO Auto-generated catch block
e1.printStackTrace();
}
finally {
fileIn.close();
}
}
}
if(e.getSource()==saveItem) {
JFileChooser fileChooser = new JFileChooser();
fileChooser.setCurrentDirectory(new File("."));

int response = fileChooser.showSaveDialog(null);

if(response == JFileChooser.APPROVE_OPTION) {
File file;
PrintWriter fileOut = null;

file = new File(fileChooser.getSelectedFile().getAbsolutePath());


try {
fileOut = new PrintWriter(file);
fileOut.println(textArea.getText());
}
catch (FileNotFoundException e1) {
// TODO Auto-generated catch block
e1.printStackTrace();
}
finally {
fileOut.close();
}
}
}
if(e.getSource()==exitItem) {
System.exit(0);
}
}
}

public class Main {


public static void main(String [] args){
new TextEditor();
}
}

OUTPUT

You might also like