patch-graphics_c 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159
  1. $OpenBSD: patch-graphics_c,v 1.1 2017/05/25 18:09:55 espie Exp $
  2. Index: graphics.c
  3. --- graphics.c.orig
  4. +++ graphics.c
  5. @@ -553,7 +553,7 @@ NODE *lback(NODE *arg) {
  6. }
  7. NODE *lshowturtle(NODE *args) {
  8. - prepare_to_draw;
  9. + prepare_to_draw_NULL;
  10. if (!turtle_shown) {
  11. turtle_shown = TRUE;
  12. draw_turtle();
  13. @@ -563,7 +563,7 @@ NODE *lshowturtle(NODE *args) {
  14. }
  15. NODE *lhideturtle(NODE *args) {
  16. - prepare_to_draw;
  17. + prepare_to_draw_NULL;
  18. if (turtle_shown) {
  19. draw_turtle();
  20. turtle_shown = FALSE;
  21. @@ -581,7 +581,7 @@ NODE *lsetheading(NODE *arg) {
  22. val = numeric_arg(arg);
  23. if (NOT_THROWING) {
  24. - prepare_to_draw;
  25. + prepare_to_draw_NULL;
  26. draw_turtle();
  27. if (nodetype(val) == INT)
  28. turtle_heading = (FLONUM)getint(val);
  29. @@ -685,7 +685,7 @@ NODE *lscrunch(NODE *args) {
  30. }
  31. NODE *lhome(NODE *args) {
  32. - prepare_to_draw;
  33. + prepare_to_draw_NULL;
  34. out_of_bounds = FALSE;
  35. setpos_bynumber((FLONUM)0.0, (FLONUM)0.0);
  36. draw_turtle();
  37. @@ -841,7 +841,7 @@ NODE *lsety(NODE *args) {
  38. }
  39. NODE *lwrap(NODE *args) {
  40. - prepare_to_draw;
  41. + prepare_to_draw_NULL;
  42. draw_turtle();
  43. current_mode = wrapmode;
  44. while (turtle_x > turtle_right_max) {
  45. @@ -864,7 +864,7 @@ NODE *lwrap(NODE *args) {
  46. NODE *lfence(NODE *args) {
  47. (void)lwrap(args); /* get turtle inside the fence */
  48. - prepare_to_draw;
  49. + prepare_to_draw_NULL;
  50. draw_turtle();
  51. current_mode = fencemode;
  52. draw_turtle();
  53. @@ -873,7 +873,7 @@ NODE *lfence(NODE *args) {
  54. }
  55. NODE *lwindow(NODE *args) {
  56. - prepare_to_draw;
  57. + prepare_to_draw_NULL;
  58. draw_turtle();
  59. current_mode = windowmode;
  60. draw_turtle();
  61. @@ -892,7 +892,7 @@ NODE *lturtlemode(NODE *args) {
  62. }
  63. NODE *lfill(NODE *args) {
  64. - prepare_to_draw;
  65. + prepare_to_draw_NULL;
  66. draw_turtle();
  67. logofill();
  68. draw_turtle();
  69. @@ -914,7 +914,7 @@ NODE *llabel(NODE *arg) {
  70. *print_stringptr = '\0';
  71. if (NOT_THROWING) {
  72. - prepare_to_draw;
  73. + prepare_to_draw_NULL;
  74. draw_turtle();
  75. theLength = strlen(textbuf);
  76. #ifdef mac
  77. @@ -1027,7 +1027,7 @@ NODE *lsetpencolor(NODE *arg) {
  78. NODE *val;
  79. if (NOT_THROWING) {
  80. - prepare_to_draw;
  81. + prepare_to_draw_NULL;
  82. if (is_list(car(arg))) {
  83. val = make_intnode(-1);
  84. lsetpalette(cons(val,arg));
  85. @@ -1044,7 +1044,7 @@ NODE *lsetbackground(NODE *arg) {
  86. NODE *val;
  87. if (NOT_THROWING) {
  88. - prepare_to_draw;
  89. + prepare_to_draw_NULL;
  90. if (is_list(car(arg))) {
  91. val = make_intnode(-2);
  92. lsetpalette(cons(val,arg));
  93. @@ -1064,7 +1064,7 @@ NODE *lsetpalette(NODE *args) {
  94. if (slotnum < -2) {
  95. err_logo(BAD_DATA_UNREC, slot);
  96. } else if (NOT_THROWING && ((slotnum > 7) || (slotnum < 0))) {
  97. - prepare_to_draw;
  98. + prepare_to_draw_NULL;
  99. set_palette(slotnum,
  100. (unsigned int)getint(car(arg)),
  101. (unsigned int)getint(cadr(arg)),
  102. @@ -1117,7 +1117,7 @@ NODE *lsetpensize(NODE *args) {
  103. NODE *arg;
  104. if (NOT_THROWING) {
  105. - prepare_to_draw;
  106. + prepare_to_draw_NULL;
  107. if (is_list(car(args))) {
  108. arg = pos_int_vector_arg(args);
  109. set_pen_width((int)getint(car(arg)));
  110. @@ -1141,7 +1141,7 @@ NODE *lsetpenpattern(NODE *args) {
  111. arg = err_logo(BAD_DATA, arg);
  112. if (NOT_THROWING) {
  113. - prepare_to_draw;
  114. + prepare_to_draw_NULL;
  115. set_list_pen_pattern(arg);
  116. save_pattern();
  117. done_drawing;
  118. @@ -1157,7 +1157,7 @@ NODE *lsetscrunch(NODE *args) {
  119. ynode = numeric_arg(cdr(args));
  120. if (NOT_THROWING) {
  121. - prepare_to_draw;
  122. + prepare_to_draw_NULL;
  123. draw_turtle();
  124. x_scale = (nodetype(xnode) == FLOATT) ? getfloat(xnode) :
  125. (FLONUM)getint(xnode);
  126. @@ -1294,7 +1294,7 @@ NODE *larc(NODE *arg) {
  127. else
  128. radius = getfloat(val2);
  129. - prepare_to_draw;
  130. + prepare_to_draw_NULL;
  131. draw_turtle();
  132. /* save and force turtle state */
  133. @@ -1671,7 +1671,7 @@ NODE *lloadpict(NODE *args) {
  134. lopenread(args);
  135. #endif
  136. if (NOT_THROWING) {
  137. - prepare_to_draw;
  138. + prepare_to_draw_NULL;
  139. fp = (FILE *)file_list->n_obj;
  140. restore_palette(fp);
  141. fread(&record_index, sizeof(FIXNUM), 1, fp);