mirror of
https://gitea.nishi.boats/pyrite-dev/milsko
synced 2026-01-05 00:50:53 +00:00
h
git-svn-id: http://svn2.nishi.boats/svn/milsko/trunk@27 b9cfdab3-6d41-4d17-bbe4-086880011989
This commit is contained in:
@@ -16,6 +16,7 @@ MILSKODECL void MilskoSetInteger(MilskoWidget handle, const char* key, in
|
|||||||
MILSKODECL void MilskoSetText(MilskoWidget handle, const char* key, const char* value);
|
MILSKODECL void MilskoSetText(MilskoWidget handle, const char* key, const char* value);
|
||||||
MILSKODECL int MilskoGetInteger(MilskoWidget handle, const char* key);
|
MILSKODECL int MilskoGetInteger(MilskoWidget handle, const char* key);
|
||||||
MILSKODECL const char* MilskoGetText(MilskoWidget handle, const char* key);
|
MILSKODECL const char* MilskoGetText(MilskoWidget handle, const char* key);
|
||||||
|
MILSKODECL void MilskoSetDefault(MilskoWidget handle);
|
||||||
MILSKODECL void MilskoApply(MilskoWidget handle, ...);
|
MILSKODECL void MilskoApply(MilskoWidget handle, ...);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -27,6 +27,9 @@ typedef struct _MilskoLowLevel {
|
|||||||
|
|
||||||
typedef struct _MilskoColor {
|
typedef struct _MilskoColor {
|
||||||
unsigned long pixel;
|
unsigned long pixel;
|
||||||
|
int red;
|
||||||
|
int green;
|
||||||
|
int blue;
|
||||||
}* MilskoLLColor;
|
}* MilskoLLColor;
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -2,9 +2,11 @@
|
|||||||
#include <Milsko/Milsko.h>
|
#include <Milsko/Milsko.h>
|
||||||
|
|
||||||
static void create(MilskoWidget handle) {
|
static void create(MilskoWidget handle) {
|
||||||
|
MilskoSetDefault(handle);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void draw(MilskoWidget handle) {
|
static void draw(MilskoWidget handle) {
|
||||||
|
MilskoPoint p[6];
|
||||||
}
|
}
|
||||||
|
|
||||||
MilskoClassRec MilskoButtonClassRec = {
|
MilskoClassRec MilskoButtonClassRec = {
|
||||||
|
|||||||
@@ -162,3 +162,7 @@ void MilskoApply(MilskoWidget handle, ...) {
|
|||||||
}
|
}
|
||||||
va_end(va);
|
va_end(va);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void MilskoSetDefault(MilskoWidget handle) {
|
||||||
|
MilskoSetText(handle, MilskoNbackground, MilskoDefaultBackground);
|
||||||
|
}
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
#include <Milsko/Milsko.h>
|
#include <Milsko/Milsko.h>
|
||||||
|
|
||||||
static void create(MilskoWidget handle) {
|
static void create(MilskoWidget handle) {
|
||||||
MilskoSetText(handle, MilskoNbackground, MilskoDefaultBackground);
|
MilskoSetDefault(handle);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void draw(MilskoWidget handle) {
|
static void draw(MilskoWidget handle) {
|
||||||
|
|||||||
@@ -63,6 +63,9 @@ MilskoLLColor MilskoLLAllocColor(MilskoLL handle, int r, int g, int b) {
|
|||||||
XAllocColor(handle->display, handle->colormap, &xc);
|
XAllocColor(handle->display, handle->colormap, &xc);
|
||||||
|
|
||||||
c->pixel = xc.pixel;
|
c->pixel = xc.pixel;
|
||||||
|
c->red = r;
|
||||||
|
c->green = g;
|
||||||
|
c->blue = b;
|
||||||
return c;
|
return c;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user