Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
yad
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Vladislav
yad
Commits
6156c864
Commit
6156c864
authored
May 03, 2018
by
Victor Ananjesky
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of github.com:v1cont/yad
parents
c5de754e
035fc76a
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
18 additions
and
3 deletions
+18
-3
form.c
src/form.c
+1
-1
main.c
src/main.c
+4
-0
option.c
src/option.c
+11
-0
util.c
src/util.c
+2
-2
No files found.
src/form.c
View file @
6156c864
...
...
@@ -1273,7 +1273,7 @@ form_print_field (guint fn)
{
gchar
*
fname
;
#if !GTK_CHECK_VERSION(3,0,0)
fname
=
gtk_font_button_get_font_name
(
GTK_FONT_BUTTON
(
g_slist_nth_data
(
fields
,
fn
)));
fname
=
(
gchar
*
)
gtk_font_button_get_font_name
(
GTK_FONT_BUTTON
(
g_slist_nth_data
(
fields
,
fn
)));
#else
fname
=
gtk_font_chooser_get_font
(
GTK_FONT_CHOOSER
(
g_slist_nth_data
(
fields
,
fn
)));
#endif
...
...
src/main.c
View file @
6156c864
...
...
@@ -607,7 +607,11 @@ create_dialog (void)
{
gint
ww
,
wh
,
sw
,
sh
;
gtk_window_get_size
(
GTK_WINDOW
(
dlg
),
&
ww
,
&
wh
);
#if !GTK_CHECK_VERSION(3,0,0)
gdk_window_get_geometry
(
gdk_get_default_root_window
(),
NULL
,
NULL
,
&
sw
,
&
sh
,
NULL
);
#else
gdk_window_get_geometry
(
gdk_get_default_root_window
(),
NULL
,
NULL
,
&
sw
,
&
sh
);
#endif
/* place window to specified coordinates */
if
(
!
options
.
data
.
use_posx
)
gtk_window_get_position
(
GTK_WINDOW
(
dlg
),
&
options
.
data
.
posx
,
NULL
);
...
...
src/option.c
View file @
6156c864
...
...
@@ -1041,6 +1041,7 @@ set_expander (const gchar * option_name, const gchar * value, gpointer data, GEr
options
.
data
.
expander
=
g_strdup
(
value
);
else
options
.
data
.
expander
=
""
;
return
TRUE
;
}
...
...
@@ -1127,6 +1128,8 @@ set_posx (const gchar * option_name, const gchar * value, gpointer data, GError
{
options
.
data
.
use_posx
=
TRUE
;
options
.
data
.
posx
=
atol
(
value
);
return
TRUE
;
}
static
gboolean
...
...
@@ -1134,6 +1137,8 @@ set_posy (const gchar * option_name, const gchar * value, gpointer data, GError
{
options
.
data
.
use_posy
=
TRUE
;
options
.
data
.
posy
=
atol
(
value
);
return
TRUE
;
}
static
gboolean
...
...
@@ -1193,6 +1198,8 @@ set_scroll_policy (const gchar * option_name, const gchar * value, gpointer data
options
.
hscroll_policy
=
pt
;
else
options
.
vscroll_policy
=
pt
;
return
TRUE
;
}
#if GLIB_CHECK_VERSION(2,30,0)
...
...
@@ -1200,6 +1207,8 @@ static gboolean
set_size_format
(
const
gchar
*
option_name
,
const
gchar
*
value
,
gpointer
data
,
GError
**
err
)
{
options
.
common_data
.
size_fmt
=
G_FORMAT_SIZE_IEC_UNITS
;
return
TRUE
;
}
#endif
...
...
@@ -1210,6 +1219,8 @@ set_xid_file (const gchar * option_name, const gchar * value, gpointer data, GEr
options
.
print_xid
=
TRUE
;
if
(
value
&&
value
[
0
])
options
.
xid_file
=
g_strdup
(
value
);
return
TRUE
;
}
static
gboolean
...
...
src/util.c
View file @
6156c864
...
...
@@ -198,7 +198,7 @@ get_color (GdkColor *c, guint64 alpha)
{
case
YAD_COLOR_HEX
:
if
(
options
.
color_data
.
alpha
)
res
=
g_strdup_printf
(
"#%X%X%X%X"
,
c
->
red
&
0xFF
,
c
->
green
&
0xFF
,
c
->
blue
&
0xFF
,
(
alpha
/
256
)
&
0xFF
);
res
=
g_strdup_printf
(
"#%X%X%X%X"
,
c
->
red
&
0xFF
,
c
->
green
&
0xFF
,
c
->
blue
&
0xFF
,
(
guint
)
((
alpha
/
256
)
&
0xFF
)
);
else
res
=
g_strdup_printf
(
"#%X%X%X"
,
c
->
red
&
0xFF
,
c
->
green
&
0xFF
,
c
->
blue
&
0xFF
);
break
;
...
...
@@ -636,7 +636,7 @@ show_langs ()
GList
*
lng
;
for
(
lng
=
gtk_spell_checker_get_language_list
();
lng
;
lng
=
lng
->
next
)
g_print
(
"%s
\n
"
,
lng
->
data
);
g_print
(
"%s
\n
"
,
(
gchar
*
)
lng
->
data
);
}
#endif
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment