forked from AuroraMiddleware/gtk
Merge branch 'matthiasc/for-master' into 'master'
Matthiasc/for master See merge request GNOME/gtk!3276
This commit is contained in:
commit
cba8c40aa0
@ -42,9 +42,9 @@ Creates a node like `gsk_blur_node_new()` with the given properties.
|
||||
|
||||
| property | syntax | default | printed |
|
||||
| -------- | ---------------- | ---------------------- | ----------- |
|
||||
| color | `<color>{1,4}` | black | non-default |
|
||||
| colors | `<color>{1,4}` | black | non-default |
|
||||
| outline | `<rounded-rect>` | 50 | always |
|
||||
| width | `<number>{1,4}` | 1 | non-default |
|
||||
| widths | `<number>{1,4}` | 1 | non-default |
|
||||
|
||||
Creates a node like `gsk_border_node_new()` with the given properties.
|
||||
|
||||
@ -121,7 +121,7 @@ Creates a node like `gsk_conic_gradient_node_new()` with the given properties.
|
||||
| property | syntax | default | printed |
|
||||
| -------- | ---------------- | ---------------------- | ----------- |
|
||||
| end | `<node>` | color { } | always |
|
||||
| mode | `<number>` | 0.5 | non-default |
|
||||
| progress | `<number>` | 0.5 | non-default |
|
||||
| start | `<node>` | color { } | always |
|
||||
|
||||
Creates a node like `gsk_cross_fade_node_new()` with the given properties.
|
||||
@ -246,7 +246,7 @@ Creates a node like `gsk_rounded_clip_node_new()` with the given properties.
|
||||
| property | syntax | default | printed |
|
||||
| -------- | ---------------- | ---------------------- | ----------- |
|
||||
| child | `<node>` | color { } | always |
|
||||
| shadow | `<shadow>` | black 1 1 | always |
|
||||
| shadows | `<shadow>` | black 1 1 | always |
|
||||
|
||||
Creates a node like `gsk_shadow_node_new()` with the given properties.
|
||||
|
||||
|
@ -1602,9 +1602,35 @@ gtk_spin_button_default_input (GtkSpinButton *spin_button,
|
||||
|
||||
*new_val = g_strtod (text, &err);
|
||||
if (*err)
|
||||
return GTK_INPUT_ERROR;
|
||||
else
|
||||
return FALSE;
|
||||
{
|
||||
/* try to convert with local digits */
|
||||
gint64 val = 0;
|
||||
int sign = 1;
|
||||
const char *p;
|
||||
|
||||
for (p = text; *p; p = g_utf8_next_char (p))
|
||||
{
|
||||
gunichar ch = g_utf8_get_char (p);
|
||||
|
||||
if (p == text && ch == '-')
|
||||
{
|
||||
sign = -1;
|
||||
continue;
|
||||
}
|
||||
|
||||
if (!g_unichar_isdigit (ch))
|
||||
break;
|
||||
|
||||
val = val * 10 + g_unichar_digit_value (ch);
|
||||
}
|
||||
|
||||
if (*p)
|
||||
return GTK_INPUT_ERROR;
|
||||
|
||||
*new_val = sign * val;
|
||||
}
|
||||
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
static void
|
||||
|
Loading…
Reference in New Issue
Block a user