File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Beginning Java and the fly likes text editor: arraylist Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "text editor: arraylist" Watch "text editor: arraylist" New topic
Author

text editor: arraylist

Castulo Ruiz
Greenhorn

Joined: May 08, 2009
Posts: 12
Hi, I'm trying to create a simple text editor, but I not sure how to use the method set_curr_line to change the current line int he buffer to a integer. Then it would print out the new current line. I need a push on how to do this.



jittu goud
Ranch Hand

Joined: Mar 30, 2007
Posts: 46
welcome to javaranch ....please embed your code in [CODE] tags ....
Ernest Friedman-Hill
author and iconoclast
Marshal

Joined: Jul 08, 2003
Posts: 24184
    
  34

Based on your question, I have to assume you're just starting out in Java, and didn't write this code yourself. If you wrote this, there's no way you'd need to ask this question. On the other hand, if this code was written by someone who's going to be teaching you to write code like this, my advice is to run for the hills. If this is a University course, ask for your money back, and see if you can't get the instructor fired. Holy cow, this is really something else.

In any case, I think you're expected to actually create a method called set_current_line which takes an int argument, and sets the appropriate member in the edit_buffer object. Replace the call to "STUB" with a call to the new method. Does this help at all?


[Jess in Action][AskingGoodQuestions]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: text editor: arraylist