Lines Matching defs:property

3214 /// Each property requires a unique name for identifaction that is also used for
3220 /// `nk_property_int` and `nk_propertyi`. In additional each property takes in
3271 /// nk_property_int | Integer property directly modifing a passed in value
3272 /// nk_property_float | Float property directly modifing a passed in value
3273 /// nk_property_double | Double property directly modifing a passed in value
3274 /// nk_propertyi | Integer property returning the modified int value
3275 /// nk_propertyf | Float property returning the modified float value
3276 /// nk_propertyd | Double property returning the modified double value
3280 /// Integer property directly modifing a passed in value
3282 /// To generate a unique property ID using the same label make sure to insert
3301 /// Float property directly modifing a passed in value
3303 /// To generate a unique property ID using the same label make sure to insert
3322 /// Double property directly modifing a passed in value
3324 /// To generate a unique property ID using the same label make sure to insert
3343 /// Integer property modifing a passed in value and returning the new value
3345 /// To generate a unique property ID using the same label make sure to insert
3366 /// Float property modifing a passed in value and returning the new value
3368 /// To generate a unique property ID using the same label make sure to insert
3389 /// Float property modifing a passed in value and returning the new value
3391 /// To generate a unique property ID using the same label make sure to insert
5229 struct nk_style_property property;
5422 struct nk_property_state property;
5440 * property inside `nk_style`. For example if you want a special
5980 /* property */
6012 NK_LIB void nk_property_behavior(nk_flags *ws, const struct nk_input *in, struct nk_rect property, struct nk_rect label, struct nk_rect edit, struct nk_rect empty, int *state, struct nk_property_variant *variant, float inc_per_pixel);
6014 NK_LIB void nk_do_property(nk_flags *ws, struct nk_command_buffer *out, struct nk_rect property, const char *name, struct nk_property_variant *variant, float inc_per_pixel, char *buffer, int *len, int *state, int *cursor, int *select_begin, int *select_end, const struct nk_style_property *style, enum nk_property_filter filter, struct nk_input *in, const struct nk_user_font *font, struct nk_text_edit *text_edit, enum nk_button_behavior behavior);
14284 struct nk_style_property *property;
14559 /* property */
14560 property = &style->property;
14561 nk_zero_struct(*property);
14562 property->normal = nk_style_item_color(table[NK_COLOR_PROPERTY]);
14563 property->hover = nk_style_item_color(table[NK_COLOR_PROPERTY]);
14564 property->active = nk_style_item_color(table[NK_COLOR_PROPERTY]);
14565 property->border_color = table[NK_COLOR_BORDER];
14566 property->label_normal = table[NK_COLOR_TEXT];
14567 property->label_hover = table[NK_COLOR_TEXT];
14568 property->label_active = table[NK_COLOR_TEXT];
14569 property->sym_left = NK_SYMBOL_TRIANGLE_LEFT;
14570 property->sym_right = NK_SYMBOL_TRIANGLE_RIGHT;
14571 property->userdata = nk_handle_ptr(0);
14572 property->padding = nk_vec2(4,4);
14573 property->border = 1;
14574 property->rounding = 10;
14575 property->draw_begin = 0;
14576 property->draw_end = 0;
14578 /* property buttons */
14579 button = &style->property.dec_button;
14597 style->property.inc_button = style->property.dec_button;
14599 /* property edit */
14600 edit = &style->property.edit;
16093 /* property garbage collector */
16094 if (window->property.active && window->property.old != window->property.seq &&
16095 window->property.active == window->property.prev) {
16096 nk_zero(&window->property, sizeof(window->property));
16098 window->property.old = window->property.seq;
16099 window->property.prev = window->property.active;
16100 window->property.seq = 0;
23576 struct nk_rect property, struct nk_rect label, struct nk_rect edit,
23589 nk_drag_behavior(ws, in, property, variant, inc_per_pixel);
23629 struct nk_command_buffer *out, struct nk_rect property,
23659 left.x = property.x + style->border + style->padding.x;
23660 left.y = property.y + style->border + property.h/2.0f - left.h/2;
23667 label.y = property.y + style->border + style->padding.y;
23668 label.h = property.h - (2 * style->border + 2 * style->padding.y);
23674 right.x = property.x + property.w - (right.w + style->padding.x);
23706 edit.y = property.y + style->border;
23707 edit.h = property.h - (2 * style->border);
23712 empty.y = property.y;
23713 empty.h = property.h;
23715 /* update property */
23717 nk_property_behavior(ws, in, property, label, edit, empty, state, variant, inc_per_pixel);
23719 /* draw property */
23721 nk_draw_property(out, style, &property, &label, *ws, name, name_len, font);
23749 /* property has been activated so setup buffer */
23781 /* property is now not active so convert edit text to value*/
23879 hash = nk_murmur_hash(name, (int)nk_strlen(name), win->property.seq++);
23883 /* check if property is currently hot item */
23884 if (win->property.active && hash == win->property.name) {
23885 buffer = win->property.buffer;
23886 len = &win->property.length;
23887 cursor = &win->property.cursor;
23888 state = &win->property.state;
23889 select_begin = &win->property.select_start;
23890 select_end = &win->property.select_end;
23900 /* execute property widget */
23903 in = ((s == NK_WIDGET_ROM && !win->property.active) ||
23907 select_end, &style->property, filter, in, style->font, &ctx->text_edit,
23910 if (in && *state != NK_PROPERTY_DEFAULT && !win->property.active) {
23911 /* current property is now hot */
23912 win->property.active = 1;
23913 NK_MEMCPY(win->property.buffer, buffer, (nk_size)*len);
23914 win->property.length = *len;
23915 win->property.cursor = *cursor;
23916 win->property.state = *state;
23917 win->property.name = hash;
23918 win->property.select_start = *select_begin;
23919 win->property.select_end = *select_end;
23925 /* check if previously active property is now inactive */
23932 win->property.select_start = 0;
23933 win->property.select_end = 0;
23934 win->property.active = 0;
25534 /// - 2017/06/08 (1.39.1) - Fixed property text edit handling bug caused by past `nk_widget` fix.