Guidance
指路人
g.yi.org
software / RapidQ / System / Win32 / Rapid-Q++ / rqstatusbar.h

Register 
注册
Search 搜索
首页 
Home Home
Software
Upload

  
#if !defined RQSTATUSBAR_H
#define RQSTATUSBAR_H

#include <windows.h>
#include "rqfont.h"
#include "rqcontrol.h"
#include "rqdefs.h"

typedef struct
{
    int   width;
    char* caption;
} PanelType;


class RQStatusBar: public RQControl
{
private:
    int panelCount;
    int* panelWidths;
    PanelType* panels;
    void updateParts();

protected:
    HWND handle;
    char *simpleText;

    void messageHandler(HWND, UINT, WPARAM, LPARAM);
    HWND getHandle() { return handle; }
    RQControl* getParent() { return parent; }

public:
    RQStatusBar();
    ~RQStatusBar();

    // StatusBar properties
    RQFont font;
    void setParent(RQControl&);
    void setSimpleText(char*);
    char const* getSimpleText();
    void setPanelWidth(int index, int width);
    int  getPanelWidth(int index) { return panels[index].width; }
    void setPanelCaption(int index, char const* caption);
    char const* getPanelCaption(int index) { return panels[index].caption; }

    // StatusBar methods
    void addPanel(char*);

    // StatusBar events
    void (*onResize)(RQStatusBar&);
};

#endif
掌柜推荐
 
 
¥860.00 ·
 
 
¥410.00 ·
 
 
¥288.00 ·
 
 
¥918.00 ·
 
 
¥288.00 ·
 
 
¥264.00 ·
© Sun 2024-11-24  Guidance Laboratory Inc.
Email:webmaster1g.yi.org Hits:0 Last modified:2013-08-20 12:34:44