Click here to Skip to main content
14,325,629 members

Text Editor Using C#

Rate this:
1.69 (15 votes)
Please Sign up or sign in to vote.
1.69 (15 votes)
3 Aug 2007CPOL
Text Editor for typing a new document, article, news, etc.

Introduction

This is an old style text editor that is still being used in some applications. The aim is to type a document, article, or news for users who perfectly remember using DOS commands in the past.

This text editor looks like a Pascal or C++ application under DOS, with a blue color background, white forecolor text, and is limited to 80 characters per line.

But don't look down on it; even though it looks very simple and has a flat interface, this cool text editor has many features that will give it more credit from your point of view. Here are some of the features that are available:

  • Font size
  • Fore color
  • Back color
  • Spelling checker

Screenshot - text_editor.jpg

If you want to add more features, no problems.. just follow the sample inside the code.

Using the code

This article provides the source code on the top; you can download it and see that there are two projects to build this text editor:

  1. Best.Editor
  2. Best.Main

You need to run the project under the Best.Main folder, and inside it, find the main form which calls the user control from the Best.Editor project.

Basically, the control that is used for typing text is a RichTextBox. Then, with your creativity to enhance it, define properties that will be give new features to this text editor.. example: alignment, save as, print, etc.

protected Color foreColor;
public Color z_ForeColorget 
{
    get
    {
        return foreColor;
    }

    set
    {
        foreColor = value;
    }
}

protected Color backColor; 
public Color z_BackColorget 
{
    get
    {
    return backColor;
    }

    set
    {
    backColor = value;
    }
}

Good luck, and hope it helps you..

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

ace
Web Developer
Singapore Singapore
No Biography provided

Comments and Discussions

 
Generalask you a simple question Pin
fangpipig20-Apr-11 20:42
memberfangpipig20-Apr-11 20:42 
GeneralMy vote of 5 Pin
fangpipig20-Apr-11 20:39
memberfangpipig20-Apr-11 20:39 
GeneralAhh the old days Pin
loneferret4-Aug-07 3:22
memberloneferret4-Aug-07 3:22 
GeneralRe: Ahh the old days Pin
ace4-Aug-07 3:29
memberace4-Aug-07 3:29 
GeneralGood Start Pin
aamironline3-Aug-07 4:18
memberaamironline3-Aug-07 4:18 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

Article
Posted 3 Aug 2007

Stats

76.4K views
3.7K downloads
29 bookmarked