DOC PREVIEW
TRINITY CSCI 1311 - Applet Coding
Pages 8

This preview shows page 1-2-3 out of 8 pages.

Save
View full document
View full document
Premium Document
Do you want full access? Go Premium and unlock all 8 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 8 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 8 pages.
Access to all documents
Download any document
Ad free experience
Premium Document
Do you want full access? Go Premium and unlock all 8 pages.
Access to all documents
Download any document
Ad free experience

Unformatted text preview:

Slide 1Slide 2Slide 3Slide 4Slide 5Slide 6Slide 7Slide 8Applet Coding4-12-2010Opening Discussion●What did we talk about last class?●Minute Essay comments–People positive toward Eclipse.●Down side is disincentive to learn code.–What is a kernel?Posting Our Applet●Last time we wrote a little applet and we also looked at the HTML-Documents directory where we can post things to the web.●We can start today by making a little web page and having that page display our applet.Applet Objective●I'd like for to write an “infinite notepad”. This will hit on many of the concepts we need to do other things.●You can type in lines of text that will appear near the middle of the screen.●Mouse drags will scroll around the view so you can see different strings.What We Need●Each string we enter needs the String along with an x and y position. We should create a separate class for those.●We will want a list of them to hold all the text that has been typed.●We need to keep integers for where we are currently looking.Listening for Events●One of the things that we have to do if we want to handle mouse or keyboard information in an applet (or a real Java application) is to listen for events.●In this case all the events effect the applet as a whole so we can just make the applet implement the different event listeners.●We will add those listeners in with a few lines of code in the init method because it needs to happen right at the beginning.Code●The logic for this program is mostly split between the listener methods and the paint method.Minute Essay●What questions do you have about what we did


View Full Document

TRINITY CSCI 1311 - Applet Coding

Course: Csci 1311-
Pages: 8
Documents in this Course
Arrays

Arrays

12 pages

Arrays

Arrays

10 pages

Applets

Applets

5 pages

Arrays

Arrays

8 pages

Methods

Methods

12 pages

Drawing

Drawing

8 pages

Load more
Download Applet Coding
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view Applet Coding and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view Applet Coding 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?