InterviewSolution
| 1. |
How Can We Draw A Line In A Specific Color? |
|
Answer» IDISPLAY_DrawHLine() and IDISPLAY_DrawVLine() always draw lines in black. Therefore setting CLR_USER_LINE to the desired color and then invoking IDISPLAY_DrawHLine() or IDISPLAY_DrawVLine() will not WORK. The DEFINITIONS of these two IDISPLAY macros are below. To draw a LINE in a color other than black, USE the code contained in the macro definition and change to the desired fill color. #define IDISPLAY_DrawHLine(p,x,y,len) IDISPLAY_DrawHLine() and IDISPLAY_DrawVLine() always draw lines in black. Therefore setting CLR_USER_LINE to the desired color and then invoking IDISPLAY_DrawHLine() or IDISPLAY_DrawVLine() will not work. The definitions of these two IDISPLAY macros are below. To draw a line in a color other than black, use the code contained in the macro definition and change to the desired fill color. #define IDISPLAY_DrawHLine(p,x,y,len) |
|