Changes

Jump to: navigation, search

Iolib functions 20103 - OOP344

1,448 bytes added, 22:54, 17 October 2010
How to submit your assignment
== Due date ==
Due date:Sunday, October 17th at 11:59 PM
* Simple io functions due on ???"see you section wiki page"
** Create directories under branches named as your learn id.
** Branch trunk into your branches/learnID directory and start working.
* Complex io functions: due on ???"see your section wiki page" 
== Tester Program and demo ==
=== [https://zenit.senecac.on.ca/svn/oop344/trunk/ioltester.c ioltester.c] ===
https://zenit.senecac.on.ca/svn/oop344/trunk/ioltester.c
 
Userid: "oop344" Password: blank (no password)
 
===Demo===
* Use [http://the.earth.li/~sgtatham/putty/latest/x86/putty.exe putty] only.
* In putty configuration change the settings of "terminal/keyboard" to "Xterm R6"
* Login to matrix and type:
<big>
$ ~fardad.soleimanloo/iol
</big>
== File Names ==
== Simple Functions (Platform dependent functions; conditional compilation)==
=== void iol_init(void) ===
Displays the null-terminated string pointed to by s starting at the current cursor position. This function leaves the cursor just after the last character displayed. If the string length exceeds the available space on the current line of output, this function has undefined results. This function does not flush any output buffer.
== Complex Functions (Platform independent functions) ==
=== void iol_display(const char* str, int row, int col, int len) ===
* '''TAB''':
** if '''IsTextEditor''' is false, TAB will simply terminate the function like a Function key
** if '''IsTextEditor''' is true, TAB will insert '''CIO_TAB_SIZEIOL_TAB_SIZE''' number of spaces into the string.'''CIO_TAB_SIZEIOL_TAB_SIZE''' should be a defined "tab size" value in iol.h. If '''CIO_TAB_SIZEIOL_TAB_SIZE''' spaces cannot be inserted into the string for any reason then the inputted tab should be ignored. (See '''“[[Iolib functions 20103 - OOP344#IsTextEditor:|IsTextEditor Section #2]]”''' for more)
* '''ESCAPE''' - Terminates iol_edit() and aborts editing: '''"str"''' will contain originally passed data when leaving function. (See '''“[[Iolib functions 20103 -OOP344#IsTextEditor:|IsTextEditor Section #3]]”''' for exception)
* '''INSERT''' - toggle Insert/Overstrike mode(toggles the value of *insertmode)
**<u>In Insert mode</u>, printable characters are inserted into the string, moving the remainder of the string to the right to make room.
**<u>In Overstrike mode</u>, printable characters overwrite existing characters (if any). Note that if you are past the end of the string, printable characters are appended to the string (as long as the string isn't full) regardless of the mode.
=== Tasks missing ===
* No missing task so far
 
=== Teams with 4 members ===
 
=== Teams with 3 members ===
== Platforms ==
Distro specified installation of compilers guilds:<br />
[https://help.ubuntu.com/community/InstallingCompilers Installing Compilers in Ubuntu]<br />
 
NOTE: Some compilers don't have the ncurses library. If you are getting a message that's something like this whenever you try to compile: <p><code>iol.c:51:21: error: ncurses.h: No such file or directory</code></p>It means you don't have it installed. You will need to install that library. Simply search for 'libncurses' in your Linux distro's package manager tool (yum for fedora and apt-get for Ubuntu, or simple go to Ubuntu's Software Centre and search for it) and install the latest development library, libncurses5-dev.
To compile using gcc issue the following command:<br />
cc iolmain.c iol.c -lncurses
</big>
'''Also make sure you use [http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html Putty]for your telnet client and set the Temminal/keyboard / function keys to Xterm R6'''
=== Mac OS C++ ===
== How to submit your assignment ==
Close to the due date of the assignment, [https://zenit.senecac.on.ca/svn/oop344/trunk/ioltester.c A tester program ] called'''"iolmainioltester.c"''' will be released. This program uses your functions and does series of tests. Each test will use your functions to produce an output or perform an action. If all the output is produced or the action is performed as stated in the tester program, branch the trunk to tags under as1"Prj0.2". Then send me an email to checkout as1 "Prj0.2" and mark it. latest commit to as1 "Prj0.2" in tags indicates the time of submission and has to be before the due date/time.
Please make sure to include the project files (.vcxproj.filters & .vcxproj or .vcproj) so I can open your files easily.
<!-- To make Fardad's life easier, make sure to include the project files so he doesn't have to start a new project and add your code. --pbrown9 -->
=== Late Submission Penalty ===
10% Per day (Saturday and Sunday) counted as one day.

Navigation menu