summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorComment <tim@gray.(none)>2012-12-26 16:55:50 +0000
committerComment <tim@gray.(none)>2012-12-26 16:55:50 +0000
commitec9ae8e75b75ac312b15b717475b130c078136b9 (patch)
treedce20a6794fd9caaab93f80818ac1e0d4a4fd26d /src
parent57b3561cced6aaec85d7f638b0f881a9fe6274c9 (diff)
made a tiny change
Diffstat (limited to 'src')
-rwxr-xr-xsrc/testApp.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/testApp.cpp b/src/testApp.cpp
index 83620b9..3f60650 100755
--- a/src/testApp.cpp
+++ b/src/testApp.cpp
@@ -30,6 +30,7 @@ get and set clipboard (ofxFensterManager.h)
*/
editorWindow::~editorWindow(){
cout << "editor window destroyed" << endl;
+
}
void editorWindow::setup(){
ofxFenster* win=ofxFensterManager::get()->createFenster(0, 0, 600, 600, OF_WINDOW);
@@ -41,7 +42,7 @@ void editorWindow::setup(){
void editorWindow::draw(){
for (int i=0;i<text.size();i++) {
- ofDrawBitmapString(text[i],10,15+(i*10));
+ ofDrawBitmapString(text[i],10,15+(i*12));
}
//draw blinking cursor
/*
@@ -65,12 +66,13 @@ void editorWindow::draw(){
void editorWindow::keyPressed(int key){
switch (key) {
case OF_KEY_RETURN:
- text+="\n";
+ text.push_back(string(""));
+ insertionPoint.row=text.size()-1;
break;
default:
char buf[2];
sprintf(buf,"%c",key);
- text+=buf;
+ text[insertionPoint.row]+=buf;
}
}
void editorWindow::keyReleased(int key){