question: How do I implement a basic CUI in c++?

  • (3 Pages)
  • +
  • 1
  • 2
  • 3

32 Replies - 2700 Views - Last Post: 02 October 2012 - 07:57 PM Rate Topic: -----

#31 jimblumberg  Icon User is offline

  • member icon


Reputation: 3845
  • View blog
  • Posts: 11,735
  • Joined: 25-December 09

Re: question: How do I implement a basic CUI in c++?

Posted 02 October 2012 - 09:09 AM

I don't see a problem. Use the standard input methods. They allow the user to edit their entry until they press the enter key. A normal text editor has everything in memory until the user saves the changes. So normally you would read the entire file to be edited into a memory buffer, alter that buffer, and finally write the file to disk when finished editing.

Jim
Was This Post Helpful? 1
  • +
  • -

#32 Skydiver  Icon User is offline

  • Code herder
  • member icon

Reputation: 3160
  • View blog
  • Posts: 9,532
  • Joined: 05-May 12

Re: question: How do I implement a basic CUI in c++?

Posted 02 October 2012 - 09:44 AM

Yeah, the Turbo C++ manuals were closer to about 6-8 lbs. I used to lug them to school everyday until I got enough money to rent a locker.

There was also the "Turbo Editor Toolkit" that had the full source code for a text editor that had the look and feel of all the Borland IDE's. I remember spending sometime porting it from Pascal to C, and then replacing the UI parts of it to use curses.h so that it would work on the UNIX workstations. Of course, in the process of porting to UNIX, I was forced to learn enough 'vi', so in the end, ended up not using the editor that I painstakingly ported.
Was This Post Helpful? 0
  • +
  • -

#33 #define  Icon User is offline

  • Duke of Err
  • member icon

Reputation: 1276
  • View blog
  • Posts: 4,395
  • Joined: 19-February 09

Re: question: How do I implement a basic CUI in c++?

Posted 02 October 2012 - 07:57 PM

Reference la Peter Norton.

Borland C++ 2.x ( with Turbo C ) - Norton Guide
Was This Post Helpful? 0
  • +
  • -

  • (3 Pages)
  • +
  • 1
  • 2
  • 3