Changeset 40943
- Timestamp:
- Oct 13, 2019, 1:17:00 PM (7 years ago)
- Location:
- branches/eam_branches/ohana.20190329/src/kapa2/src
- Files:
-
- 3 edited
-
InterpretKeys.c (modified) (2 diffs)
-
Refresh.c (modified) (3 diffs)
-
bDrawOverlay.c (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branches/ohana.20190329/src/kapa2/src/InterpretKeys.c
r38465 r40943 160 160 break; 161 161 162 case XK_plus: 163 case XK_equal: 162 164 case XK_KP_Add: 163 165 if (modstate & ControlMask) { … … 171 173 Reorient (graphic, image, image[0].picture.Xc, image[0].picture.Yc, 0); 172 174 break; 175 176 case XK_minus: 177 case XK_underscore: 173 178 case XK_KP_Subtract: 174 179 if (modstate & ControlMask) { -
branches/eam_branches/ohana.20190329/src/kapa2/src/Refresh.c
r40927 r40943 1 1 # include "Ximage.h" 2 2 3 # define USE_BUFFERED_DRAW 03 # define USE_BUFFERED_DRAW 1 4 4 5 5 void bDrawXimage (bDrawBuffer *buffer); … … 47 47 for (int i = 0; i < Nsection; i++) { 48 48 Section *section = GetSectionByNumber (i); 49 DrawImageTool (section->image); 49 50 KapaImageWidget *image = section->image; 51 DrawImageTool (image); 52 53 /*** PaintOverlay is called in DrawImage *** 54 if (!image) continue; 55 for (int j = 0; j < NOVERLAYS; j++) { 56 if (image[0].overlay[j].active) { 57 PaintOverlay (graphic, image, j); 58 } 59 } 60 */ 50 61 } 62 51 63 FlushDisplay (); 52 64 } … … 71 83 Nsection = GetNumberOfSections (); 72 84 for (i = 0; i < Nsection; i++) { 73 section = GetSectionByNumber (i); 74 DrawSectionBG (graphic, section); 75 DrawImage (section->image); 76 DrawGraph (section->graph); 85 section = GetSectionByNumber (i); 86 DrawSectionBG (graphic, section); 87 88 KapaImageWidget *image = section->image; 89 DrawImage (image); 90 DrawImageTool (image); 91 92 /*** the overlay is added in DrawImage ***/ 93 if (image) { 94 for (int j = 0; j < NOVERLAYS; j++) { 95 if (image[0].overlay[j].active) { 96 PaintOverlay (graphic, image, j); 97 } 98 } 99 } 100 101 DrawGraph (section->graph); 77 102 } 78 103 -
branches/eam_branches/ohana.20190329/src/kapa2/src/bDrawOverlay.c
r40558 r40943 24 24 } 25 25 26 Xmin = 0; 27 Ymin = 0; 28 Xmax = image[0].picture.dx; 29 Ymax = image[0].picture.dy; 26 // Xmin = 0; 27 // Ymin = 0; 28 // Xmax = image[0].picture.dx; 29 // Ymax = image[0].picture.dy; 30 31 Xmin = image[0].picture.x; 32 Ymin = image[0].picture.y; 33 Xmax = image[0].picture.x + image[0].picture.dx; // maybe this should be just dx? 34 Ymax = image[0].picture.y + image[0].picture.dy; 30 35 31 36 if (N == INFRONT) { … … 35 40 36 41 for (i = 0; i < image[0].overlay[N].Nobjects; i++) { 37 Image_to_Picture (&X, &Y, image[0].overlay[N].objects[i].x, image[0].overlay[N].objects[i].y, &image[0].picture); 42 // XXX the 0.5,0.5 offset is apparently needed here. 43 // work on rationalizing these functions in the context of their different plotting types 44 Image_to_Screen (&X, &Y, image[0].overlay[N].objects[i].x - 0.5, image[0].overlay[N].objects[i].y - 0.5, &image[0].picture); 38 45 dX = image[0].overlay[N].objects[i].dx * expand; 39 46 dY = image[0].overlay[N].objects[i].dy * expand;
Note:
See TracChangeset
for help on using the changeset viewer.
