Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Text Editor in C (Univ assignment)

Name: Anonymous 2011-01-12 4:39

So hey guys :3

I've got this paper that I have to do, and I need to make a text editor. Please assist me and offer tips as I'm currently trying to think this thing through before I get to the actual coding.

•I'm going to be saving everything in a 20x80 matrix, or a string[1601] so I can use every individual character written, is this correct? (I'm declaring the maximum number of chars on screen to 20 lines with 80 columns, fuck anything more, this is a first semester assignment, hence the matric and string lengths)

•How on earth does I shot cursor? I mean, I'm supposed to have the cursor move up and down so the user can write at different parts of his text. Now, I can think of a way to shove the characters of the string "left" or "right" by making an individual proc, but how would one actually go and make the cursor move? Any ideas would be welcome.

•I'm unfamiliar with C extracting anything in .txt format, derp, will google later. Everything we've worked so far is hurrr command prompt calculations.

•In general, any ideas from you experienced coders, feedback, tips, anything, will be bloody welcome. Although I've worked with BYOND and Space Station 13 (/tg/station13) before so I'm familiar with reading Spaghetti code or structured coding using and calling procs() (oh hey I can probably go look at the code there and gather ideas and code formations) I think I'm at a stage where, being confused, I don't even know what QUESTIONS to ask to myself before I start solving the problem.

Just for the record, im studying CS at AUTH university, greece.

Name: Anonymous 2011-01-12 13:39

OP here.

I'm a bit lost.

We've never used pointers.
We're supposed to make it through Windows Command Prompt
We're supposed to limit the size of the editor, hence the 20x80=1600 string
Our "knowledge" goes as far as using procedures outside main(), but I've been reading on pointers alone. Frankly, I don't get em yet. I need a good 2-hour sitting reading online tutorials and I think I can get em.

Hopefully, this answers your questions.

And yes, 1601 is due to the last stringend character. Also sage.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List