Develop and Download Open Source Software

Browse CVS Repository

Diff of /ttssh2/teraterm/source/teraterm/vtdisp.c

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.17 by yutakapon, Thu Jan 24 11:38:42 2008 UTC revision 1.18 by yutakapon, Fri Jan 25 11:33:02 2008 UTC
# Line 1718  void CaretKillFocus(BOOL show) Line 1718  void CaretKillFocus(BOOL show)
1718    p[0].y = CaretY;    p[0].y = CaretY;
1719    p[1].x = CaretX;    p[1].x = CaretX;
1720    p[1].y = CaretY + FontHeight - 1;    p[1].y = CaretY + FontHeight - 1;
1721    p[2].x = CaretX + FontWidth - 1;    if (CursorOnDBCS)
1722            p[2].x = CaretX + FontWidth*2 - 1;
1723      else
1724            p[2].x = CaretX + FontWidth - 1;
1725    p[2].y = CaretY + FontHeight - 1;    p[2].y = CaretY + FontHeight - 1;
1726    p[3].x = CaretX + FontWidth - 1;    if (CursorOnDBCS)
1727            p[3].x = CaretX + FontWidth*2 - 1;
1728      else
1729            p[3].x = CaretX + FontWidth - 1;
1730    p[3].y = CaretY;    p[3].y = CaretY;
1731    p[4].x = CaretX;    p[4].x = CaretX;
1732    p[4].y = CaretY;    p[4].y = CaretY;
1733    
1734    if (show) {    if (show) {  // ポリゴンカーソルを表示(非フォーカス時)
1735            oldpen = SelectObject(hdc, CreatePen(PS_SOLID, 0, ts.VTColor[0]));            oldpen = SelectObject(hdc, CreatePen(PS_SOLID, 0, ts.VTColor[0]));
1736    } else {    } else {
1737            oldpen = SelectObject(hdc, CreatePen(PS_SOLID, 0, ts.VTColor[1]));            oldpen = SelectObject(hdc, CreatePen(PS_SOLID, 0, ts.VTColor[1]));
# Line 1738  void CaretKillFocus(BOOL show) Line 1744  void CaretKillFocus(BOOL show)
1744    DispReleaseDC();    DispReleaseDC();
1745  }  }
1746    
1747    // ポリゴンカーソルを消したあとに、その部分の文字を再描画する。
1748    //
1749    // CaretOff()の直後に呼ぶこと。CaretOff()内から呼ぶと、無限再帰呼び出しとなり、
1750    // stack overflowになる。
1751    void UpdateCaretKillFocus(void)
1752    {
1753      int CaretX, CaretY;
1754      RECT rc;
1755    
1756      CaretX = (CursorX-WinOrgX)*FontWidth;
1757      CaretY = (CursorY-WinOrgY)*FontHeight;
1758    
1759      if (ts.KillFocusCursor == 0)
1760              return;
1761    
1762      // Eterm lookfeelの場合は何もしない
1763      if (BGEnable)
1764              return;
1765    
1766      if (! Active) {
1767              rc.left = CaretX;
1768              rc.top = CaretY;
1769              if (CursorOnDBCS)
1770                    rc.right = CaretX + FontWidth*2 - 1;
1771              else
1772                    rc.right = CaretX + FontWidth - 1;
1773              rc.bottom = CaretY + FontHeight - 1;
1774              InvalidateRect(HVTWin, &rc, FALSE);
1775      }
1776    }
1777    
1778  void CaretOn()  void CaretOn()
1779  // Turn on the cursor  // Turn on the cursor
1780  {  {

Legend:
Removed from v.1.17  
changed lines
  Added in v.1.18

Back to OSDN">Back to OSDN
ViewVC Help
Powered by ViewVC 1.1.26