tab widget
Some checks failed
pyrite-dev/milsko/pipeline/head There was a failure building this commit
Some checks failed
pyrite-dev/milsko/pipeline/head There was a failure building this commit
This commit is contained in:
parent
6eefe44f6f
commit
1c2cd6e875
21 changed files with 451 additions and 51 deletions
|
|
@ -93,7 +93,6 @@ MWDECL void MWAPI MwDrawTriangle(MwWidget handle, MwRect* rect, MwLLColor color,
|
|||
* @param border Border width
|
||||
* @param diff Difference (set this to 0 if you don't know what this does)
|
||||
* @param same Same as dark color
|
||||
* @param rounded Rounded or not
|
||||
* @warning `rect` gets changed to the area of rectangle inside
|
||||
*/
|
||||
MWDECL void MWAPI MwDrawFrameEx(MwWidget handle, MwRect* rect, MwLLColor color, int invert, int border, int diff, int same);
|
||||
|
|
|
|||
|
|
@ -331,6 +331,8 @@ MWDECL MwBool (*MwLLDoModern)(MwLL handle);
|
|||
|
||||
MWDECL void (*MwLLRaise)(MwLL handle);
|
||||
|
||||
MWDECL void (*MwLLClip)(MwLL handle, MwRect* rect);
|
||||
|
||||
/* font renderer */
|
||||
MWDECL void MwFLSetup(void);
|
||||
|
||||
|
|
|
|||
|
|
@ -562,7 +562,6 @@ struct _MwLLWayland {
|
|||
cairo_t* back_cairo;
|
||||
/* The cairo to actually use for draw operations. Typically is front_cairo, but MwLLBeginDraw can change this to the back_cairo so it can be used to draw window decorations. */
|
||||
cairo_t* selected_cairo;
|
||||
|
||||
};
|
||||
|
||||
struct _MwLLWaylandColor {
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@ struct _MwLLX11 {
|
|||
XIC xic;
|
||||
|
||||
long clipboard_time;
|
||||
int clipboard_pending; /* 1 if UTF8_STRING, 2 if COMPOUNd_TEXT, 3 if TEXT, 4 if STRING, otherwise 0 */
|
||||
int clipboard_pending; /* 1 if UTF8_STRING, 2 if COMPOUND_TEXT, 3 if TEXT, 4 if STRING, otherwise 0 */
|
||||
|
||||
int top;
|
||||
int toplevel;
|
||||
|
|
|
|||
|
|
@ -50,6 +50,7 @@
|
|||
#include <Mw/Widget/Separator.h>
|
||||
#include <Mw/Widget/SubMenu.h>
|
||||
#include <Mw/Widget/SubWindow.h>
|
||||
#include <Mw/Widget/Tab.h>
|
||||
#include <Mw/Widget/TreeView.h>
|
||||
#include <Mw/Widget/Viewport.h>
|
||||
#include <Mw/Widget/Window.h>
|
||||
|
|
|
|||
|
|
@ -28,6 +28,7 @@ typedef struct _MwTreeViewEntry MwTreeViewEntry;
|
|||
typedef struct _MwDirectoryEntry MwDirectoryEntry;
|
||||
typedef struct _MwBox* MwBox;
|
||||
typedef struct _MwSubWindow* MwSubWindow;
|
||||
typedef struct _MwTab* MwTab;
|
||||
typedef struct _MwMouse MwMouse;
|
||||
#ifdef _MILSKO
|
||||
typedef struct _MwWidget* MwWidget;
|
||||
|
|
@ -224,6 +225,11 @@ struct _MwSubWindow {
|
|||
MwPoint base;
|
||||
};
|
||||
|
||||
struct _MwTab {
|
||||
MwWidget* frames;
|
||||
char** names;
|
||||
};
|
||||
|
||||
struct _MwMouse {
|
||||
MwPoint point;
|
||||
int button;
|
||||
|
|
|
|||
49
include/Mw/Widget/Tab.h
Normal file
49
include/Mw/Widget/Tab.h
Normal file
|
|
@ -0,0 +1,49 @@
|
|||
/*!
|
||||
* @file Mw/Widget/Tab.h
|
||||
* @brief Tab widget
|
||||
*/
|
||||
#ifndef __MW_WIDGET_TAB_H__
|
||||
#define __MW_WIDGET_TAB_H__
|
||||
|
||||
#include <Mw/MachDep.h>
|
||||
#include <Mw/TypeDefs.h>
|
||||
#include <Mw/Core.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*!
|
||||
* @brief Tab widget class
|
||||
*/
|
||||
MWDECL MwClass MwTabClass;
|
||||
|
||||
/*!
|
||||
* @brief Adds a tab
|
||||
* @param handle Widget
|
||||
* @param name Tab name
|
||||
* @return Frame
|
||||
*/
|
||||
MwInline MwWidget MwTabAdd(MwWidget handle, const char* name) {
|
||||
MwWidget out;
|
||||
MwVaWidgetExecute(handle, "mwTabAdd", &out, name);
|
||||
return out;
|
||||
}
|
||||
|
||||
/*!
|
||||
* @brief Gets a tab frame
|
||||
* @param handle Widget
|
||||
* @param name Tab name
|
||||
* @return Frame
|
||||
*/
|
||||
MwInline MwWidget MwTabGetFrame(MwWidget handle, const char* name) {
|
||||
MwWidget out;
|
||||
MwVaWidgetExecute(handle, "mwTabGetFrame", &out, name);
|
||||
return out;
|
||||
}
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
Loading…
Add table
Add a link
Reference in a new issue