Merge branch 'master' into allegro5_impl

This commit is contained in:
seibelj 2016-12-31 14:00:58 -05:00
commit eb58042b1a
7 changed files with 18 additions and 14 deletions

View File

@ -1,4 +1,5 @@
# Changelog
- 2016/12/31 (1.192)- Fixed closing window bug of minimized windows
- 2016/12/03 (1.191)- Fixed wrapped text with no seperator and C89 error
- 2016/12/03 (1.19) - Changed text wrapping to process words not characters
- 2016/11/22 (1.184)- Fixed window minimized closing bug

View File

@ -177,12 +177,12 @@ int main(void)
/* Load Cursor: if you uncomment cursor loading please hide the cursor */
{struct nk_font_atlas *atlas;
nk_d3d11_font_stash_begin(&atlas);
/*struct nk_font *droid = nk_font_atlas_add_from_file(atlas, "../../../extra_font/DroidSans.ttf", 14, 0);*/
/*struct nk_font *robot = nk_font_atlas_add_from_file(atlas, "../../../extra_font/Robot-Regular.ttf", 14, 0);*/
/*struct nk_font *future = nk_font_atlas_add_from_file(atlas, "../../../extra_font/kenvector_future_thin.ttf", 13, 0);*/
/*struct nk_font *clean = nk_font_atlas_add_from_file(atlas, "../../../extra_font/ProggyClean.ttf", 12, 0);*/
/*struct nk_font *tiny = nk_font_atlas_add_from_file(atlas, "../../../extra_font/ProggyTiny.ttf", 10, 0);*/
/*struct nk_font *cousine = nk_font_atlas_add_from_file(atlas, "../../../extra_font/Cousine-Regular.ttf", 13, 0);*/
/*struct nk_font *droid = nk_font_atlas_add_from_file(atlas, "../../extra_font/DroidSans.ttf", 14, 0);*/
/*struct nk_font *robot = nk_font_atlas_add_from_file(atlas, "../../extra_font/Roboto-Regular.ttf", 14, 0);*/
/*struct nk_font *future = nk_font_atlas_add_from_file(atlas, "../../extra_font/kenvector_future_thin.ttf", 13, 0);*/
/*struct nk_font *clean = nk_font_atlas_add_from_file(atlas, "../../extra_font/ProggyClean.ttf", 12, 0);*/
/*struct nk_font *tiny = nk_font_atlas_add_from_file(atlas, "../../extra_font/ProggyTiny.ttf", 10, 0);*/
/*struct nk_font *cousine = nk_font_atlas_add_from_file(atlas, "../../extra_font/Cousine-Regular.ttf", 13, 0);*/
nk_d3d11_font_stash_end();
/*nk_style_load_all_cursors(ctx, atlas->cursors);*/
/*nk_style_set_font(ctx, &droid->handle)*/;}

View File

@ -392,13 +392,13 @@ nk_gdip_stroke_rect(short x, short y, unsigned short w,
} else {
INT d = 2 * r;
GdipDrawArcI(gdip.memory, gdip.pen, x, y, d, d, 180, 90);
GdipDrawLineI(gdip.memory, gdip.pen, x + d, y, x + w - d, y);
GdipDrawLineI(gdip.memory, gdip.pen, x + r, y, x + w - r, y);
GdipDrawArcI(gdip.memory, gdip.pen, x + w - d, y, d, d, 270, 90);
GdipDrawLineI(gdip.memory, gdip.pen, x + w, y + d, x + w, y + h - d);
GdipDrawLineI(gdip.memory, gdip.pen, x + w, y + r, x + w, y + h - r);
GdipDrawArcI(gdip.memory, gdip.pen, x + w - d, y + h - d, d, d, 0, 90);
GdipDrawLineI(gdip.memory, gdip.pen, x, y + d, x + w, y + h - d);
GdipDrawLineI(gdip.memory, gdip.pen, x, y + r, x, y + h - r);
GdipDrawArcI(gdip.memory, gdip.pen, x, y + h - d, d, d, 90, 90);
GdipDrawLineI(gdip.memory, gdip.pen, x + d, y + h, x + w - d, y + h);
GdipDrawLineI(gdip.memory, gdip.pen, x + r, y + h, x + w - r, y + h);
}
}

View File

@ -302,7 +302,7 @@ nk_glfw3_new_frame(void)
if (glfwGetKey(win, GLFW_KEY_LEFT_CONTROL) == GLFW_PRESS ||
glfwGetKey(win, GLFW_KEY_RIGHT_CONTROL) == GLFW_PRESS) {
nk_input_key(ctx, NK_KEY_COPY, glfwGetKey(win, GLFW_KEY_C) == GLFW_PRESS);
nk_input_key(ctx, NK_KEY_PASTE, glfwGetKey(win, GLFW_KEY_P) == GLFW_PRESS);
nk_input_key(ctx, NK_KEY_PASTE, glfwGetKey(win, GLFW_KEY_V) == GLFW_PRESS);
nk_input_key(ctx, NK_KEY_CUT, glfwGetKey(win, GLFW_KEY_X) == GLFW_PRESS);
nk_input_key(ctx, NK_KEY_TEXT_UNDO, glfwGetKey(win, GLFW_KEY_Z) == GLFW_PRESS);
nk_input_key(ctx, NK_KEY_TEXT_REDO, glfwGetKey(win, GLFW_KEY_R) == GLFW_PRESS);

View File

@ -410,7 +410,7 @@ nk_glfw3_new_frame(void)
if (glfwGetKey(win, GLFW_KEY_LEFT_CONTROL) == GLFW_PRESS ||
glfwGetKey(win, GLFW_KEY_RIGHT_CONTROL) == GLFW_PRESS) {
nk_input_key(ctx, NK_KEY_COPY, glfwGetKey(win, GLFW_KEY_C) == GLFW_PRESS);
nk_input_key(ctx, NK_KEY_PASTE, glfwGetKey(win, GLFW_KEY_P) == GLFW_PRESS);
nk_input_key(ctx, NK_KEY_PASTE, glfwGetKey(win, GLFW_KEY_V) == GLFW_PRESS);
nk_input_key(ctx, NK_KEY_CUT, glfwGetKey(win, GLFW_KEY_X) == GLFW_PRESS);
nk_input_key(ctx, NK_KEY_TEXT_UNDO, glfwGetKey(win, GLFW_KEY_Z) == GLFW_PRESS);
nk_input_key(ctx, NK_KEY_TEXT_REDO, glfwGetKey(win, GLFW_KEY_R) == GLFW_PRESS);

View File

@ -16062,7 +16062,8 @@ nk_clear(struct nk_context *ctx)
iter = ctx->begin;
while (iter) {
/* make sure minimized windows do not get removed */
if (iter->flags & NK_WINDOW_MINIMIZED) {
if ((iter->flags & NK_WINDOW_MINIMIZED) &&
!(iter)->flags & NK_WINDOW_CLOSED) {
iter = iter->next;
continue;
}
@ -17253,6 +17254,8 @@ nk_begin_titled(struct nk_context *ctx, const char *name, const char *title,
/* update window */
win->flags &= ~(nk_flags)(NK_WINDOW_PRIVATE-1);
win->flags |= flags;
if (!(win->flags & (NK_WINDOW_MOVABLE | NK_WINDOW_SCALABLE)))
win->bounds = bounds;
/* If this assert triggers you either:
*
* I.) Have more than one window with the same name or