有谁用过SCROLLBARINFO 结构吗,它的最后成员是DWORD rgstate[CCHILDREN_SCROLLBAR+1];
有关这个成员的意义,MSDN上这么解释的,看不明白呀:
The DWORD element for each scroll bar component can include a combination of the following bit flags.STATE_SYSTEM_INVISIBLE
For the scroll bar itself, indicates the specified vertical or horizontal scroll bar does not exist. For the page up or page down regions, indicates the thumb is positioned such that the region does not exist.
STATE_SYSTEM_OFFSCREEN
For the scroll bar itself, indicates the window is sized such that the specified vertical or horizontal scroll bar is not currently displayed.
多谢各位大侠赐教了!

解决方案 »

  1.   

    The DWORD element 是 STATE_SYSTEM_INVISIBLE和STATE_SYSTEM_OFFSCREEN的联合,表示在不同的情况下水平或者垂直的scroll bar不显示。
      

  2.   

    typedef struct tagSCROLLBARINFO {
      DWORD cbSize;//初始化结构体,须赋值sizeof(SCROLLBARINFO),也就是结构体大小
      RECT  rcScrollBar;//滚动条大小,位置,这个是相对于屏幕,不受父窗口限制。也就是调用GetWindowRect函数获取的大小。
      int   dxyLineButton;//按钮宽度(水平),或按钮高度(垂直)
      int   xyThumbTop;//滑块左边位置(水平),滑块顶部位置(垂直),这个位置是相对于滚动条的。
      int   xyThumbBottom;//滑块右边位置(水平),滑块底部位置(垂直)。相对于滚动条
      int   reserved;//预留
      DWORD rgstate[CCHILDREN_SCROLLBAR+1];//指明各组件状态,如按钮被按下,详细查MSDN,这个例子不会用到它。
    } SCROLLBARINFO, *PSCROLLBARINFO, *LPSCROLLBARINFO;