about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--029tools.cc20
-rw-r--r--070display.cc13
-rw-r--r--071print.mu2
-rw-r--r--edit.mu19
4 files changed, 7 insertions, 47 deletions
diff --git a/029tools.cc b/029tools.cc
index 232c484b..12840d90 100644
--- a/029tools.cc
+++ b/029tools.cc
@@ -260,23 +260,3 @@ case _DUMP_MEMORY: {
   dump_memory();
   break;
 }
-
-:(before "End Primitive Recipe Declarations")
-_LOG,
-:(before "End Primitive Recipe Numbers")
-Recipe_ordinal["$log"] = _LOG;
-:(before "End Primitive Recipe Implementations")
-case _LOG: {
-//?   ofstream fout("log", ofstream::app);
-//?   for (long long int i = 0; i < SIZE(current_instruction().ingredients); ++i) {
-//?     fout << print_mu(current_instruction().ingredients.at(i), ingredients.at(i));
-//?   }
-//?   fout << '\n';
-//?   fout.close();
-  ostringstream out;
-  for (long long int i = 0; i < SIZE(current_instruction().ingredients); ++i) {
-    out << print_mu(current_instruction().ingredients.at(i), ingredients.at(i));
-  }
-  trace(1, "app") << out.str() << end();
-  break;
-}
diff --git a/070display.cc b/070display.cc
index 2429f42d..45ddb5e6 100644
--- a/070display.cc
+++ b/070display.cc
@@ -1,9 +1,5 @@
 //: Take charge of the text-mode display and console.
 
-:(before "End Globals")
-// uncomment to debug console programs
-//? ofstream LOG("log.txt");
-
 //:: Display management
 
 :(before "End Globals")
@@ -50,7 +46,6 @@ Recipe_ordinal["clear-display"] = CLEAR_DISPLAY;
 case CLEAR_DISPLAY: {
   tb_clear();
   Display_row = Display_column = 0;
-//?   tb_present();
   break;
 }
 
@@ -104,10 +99,6 @@ case PRINT_CHARACTER_TO_DISPLAY: {
     bg_color = ingredients.at(2).at(0);
     if (bg_color == 0) bg_color = TB_BLACK;
   }
-//?   ofstream fout("log", ofstream::app);
-//?   fout << "displaying at " << Display_row << ", " << Display_column << ": " << (int)c << " in color " << color << ", " << bg_color << '\n';
-//?   fout.close();
-  trace(1, "app") << "displaying at " << Display_row << ", " << Display_column << ": " << (int)c << " in color " << color << ", " << bg_color << end();
   tb_change_cell(Display_column, Display_row, c, color, bg_color);
   if (c == '\n' || c == '\r') {
     if (Display_row < height-1) {
@@ -119,10 +110,6 @@ case PRINT_CHARACTER_TO_DISPLAY: {
     break;
   }
   if (c == '\b') {
-//?     ofstream fout("log", ofstream::app);
-//?     fout << "handling backspace\n";
-//?     fout.close();
-    trace(1, "app") << "handling backspace" << end();
     if (Display_column > 0) {
       tb_change_cell(Display_column-1, Display_row, ' ', color, bg_color);
       --Display_column;
diff --git a/071print.mu b/071print.mu
index ddaa3d1c..9732ce2f 100644
--- a/071print.mu
+++ b/071print.mu
@@ -102,7 +102,6 @@ recipe print-character [
     bg-color <- copy 0/black
   }
   trace 90, [print-character], c
-  $log [printing character] c
   {
     # if x exists
     # (handle special cases exactly like in the real screen)
@@ -393,7 +392,6 @@ recipe move-cursor [
     reply sc/same-as-ingredient:0
   }
   # otherwise, real screen
-  $log [moving cursor to] new-row new-column
   move-cursor-on-display new-row, new-column
   reply sc/same-as-ingredient:0
 ]
diff --git a/edit.mu b/edit.mu
index b0a24383..611fc23c 100644
--- a/edit.mu
+++ b/edit.mu
@@ -1600,8 +1600,7 @@ recipe delete-before-cursor [
     loop
   }
   # we're guaranteed not to be at the right margin
-  $log [printing space for backspace]
-#?   screen <- print-character screen, 32/space
+  screen <- print-character screen, 32/space
   reply editor/same-as-ingredient:0, screen/same-as-ingredient:1, 0/no-more-render
 ]
 
@@ -4775,10 +4774,10 @@ recipe render-all [
   local-scope
   screen:address <- next-ingredient
   env:address:programming-environment-data <- next-ingredient
-  $log [--- render all]
+  trace 10, [app], [render all]
   hide-screen screen
   # top menu
-  $log [-- top menu]
+  trace 11, [app], [render top menu]
   width:number <- screen-width screen
   draw-horizontal screen, 0, 0/left, width, 32/space, 0/black, 238/grey
   button-start:number <- subtract width, 20
@@ -4788,7 +4787,7 @@ recipe render-all [
   run-button:address:array:character <- new [ run (F4) ]
   print-string screen, run-button, 255/white, 161/reddish
   # error message
-  $log [-- status]
+  trace 11, [app], [render status]
   recipe-warnings:address:array:character <- get *env, recipe-warnings:offset
   {
     break-unless recipe-warnings
@@ -4796,7 +4795,7 @@ recipe render-all [
     update-status screen, status, 1/red
   }
   # dotted line down the middle
-  $log [-- vertical line]
+  trace 11, [app], [render divider]
   divider:number, _ <- divide-with-remainder width, 2
   height:number <- screen-height screen
   draw-vertical screen, divider, 1/top, height, 9482/vertical-dotted
@@ -4842,7 +4841,7 @@ recipe render-recipes [
   local-scope
   screen:address <- next-ingredient
   env:address:programming-environment-data <- next-ingredient
-  $log [-- render recipes]
+  trace 11, [app], [render recipes]
   recipes:address:editor-data <- get *env, recipes:offset
   # render recipes
   left:number <- get *recipes, left:offset
@@ -4897,9 +4896,6 @@ after +global-type [
   {
     ctrl-l?:boolean <- equal *c, 12/ctrl-l
     break-unless ctrl-l?
-    $log [=== ctrl-l pressed]
-#?     screen <- clear-screen screen
-    clear-display
     screen <- render-all screen, env:address:programming-environment-data
     loop +next-event:label
   }
@@ -5254,8 +5250,7 @@ recipe render-sandbox-side [
   local-scope
   screen:address <- next-ingredient
   env:address:programming-environment-data <- next-ingredient
-  $log [-- render sandbox side]
-#?   trace 10, [app], [render sandbox side] #? 1
+  trace 11, [app], [render sandbox side]
   current-sandbox:address:editor-data <- get *env, current-sandbox:offset
   left:number <- get *current-sandbox, left:offset
   right:number <- get *current-sandbox, right:offset