Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
4e22e0f4e7 | ||
|
|
d6a40c7523 | ||
|
|
4ee2f4e7de | ||
|
|
1567e56a09 | ||
|
|
639ccbf16c |
@@ -82,7 +82,13 @@ if( NOT IMLIB_BUILD_WITH_X )
|
|||||||
message( FATAL_ERROR "Imlib is not built with X support" )
|
message( FATAL_ERROR "Imlib is not built with X support" )
|
||||||
endif( NOT IMLIB_BUILD_WITH_X )
|
endif( NOT IMLIB_BUILD_WITH_X )
|
||||||
|
|
||||||
add_definitions( -D_POSIX_C_SOURCE=200809L -D_BSD_SOURCE -D_DEFAULT_SOURCE )
|
|
||||||
|
if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
|
||||||
|
add_definitions( -D_POSIX_C_SOURCE=200809L -D_BSD_SOURCE -D_DEFAULT_SOURCE )
|
||||||
|
else(CMAKE_SYSTEM_NAME STREQUAL "Linux")
|
||||||
|
add_definitions( -D_WITH_GETLINE )
|
||||||
|
endif(CMAKE_SYSTEM_NAME STREQUAL "Linux")
|
||||||
|
|
||||||
|
|
||||||
include_directories( ${PROJECT_BINARY_DIR}
|
include_directories( ${PROJECT_BINARY_DIR}
|
||||||
src
|
src
|
||||||
@@ -243,7 +249,7 @@ endif( RT_LIBRARY )
|
|||||||
target_link_libraries( tint2 m )
|
target_link_libraries( tint2 m )
|
||||||
|
|
||||||
add_dependencies( tint2 version )
|
add_dependencies( tint2 version )
|
||||||
set_target_properties( tint2 PROPERTIES COMPILE_FLAGS "-Wall -Wpointer-arith -fno-strict-aliasing -pthread -std=c99 ${ASAN_C_FLAGS}" )
|
set_target_properties( tint2 PROPERTIES COMPILE_FLAGS "-Wall -Wpointer-arith -fno-strict-aliasing -pthread -std=c11 ${ASAN_C_FLAGS}" )
|
||||||
set_target_properties( tint2 PROPERTIES LINK_FLAGS "-pthread -fno-strict-aliasing ${ASAN_L_FLAGS} ${BACKTRACE_L_FLAGS}" )
|
set_target_properties( tint2 PROPERTIES LINK_FLAGS "-pthread -fno-strict-aliasing ${ASAN_L_FLAGS} ${BACKTRACE_L_FLAGS}" )
|
||||||
|
|
||||||
install( TARGETS tint2 DESTINATION bin )
|
install( TARGETS tint2 DESTINATION bin )
|
||||||
|
|||||||
@@ -1,3 +1,7 @@
|
|||||||
|
2017-03-19 0.13.2
|
||||||
|
- Fixes:
|
||||||
|
- Fixed compilation under FreeBSD
|
||||||
|
|
||||||
2017-03-12 0.13.1
|
2017-03-12 0.13.1
|
||||||
- Fixes:
|
- Fixes:
|
||||||
- Fixed compilation with new glibc (issue #625)
|
- Fixed compilation with new glibc (issue #625)
|
||||||
|
|||||||
14
README.md
14
README.md
@@ -1,5 +1,5 @@
|
|||||||
# Latest stable release: 0.13.1
|
# Latest stable release: 0.13.2
|
||||||
Changes: https://gitlab.com/o9000/tint2/blob/0.13.1/ChangeLog
|
Changes: https://gitlab.com/o9000/tint2/blob/0.13.2/ChangeLog
|
||||||
|
|
||||||
Documentation: [doc/tint2.md](doc/tint2.md)
|
Documentation: [doc/tint2.md](doc/tint2.md)
|
||||||
|
|
||||||
@@ -8,7 +8,7 @@ Compile it with (after you install the [dependencies](https://gitlab.com/o9000/t
|
|||||||
```
|
```
|
||||||
git clone https://gitlab.com/o9000/tint2.git
|
git clone https://gitlab.com/o9000/tint2.git
|
||||||
cd tint2
|
cd tint2
|
||||||
git checkout 0.13.1
|
git checkout 0.13.2
|
||||||
mkdir build
|
mkdir build
|
||||||
cd build
|
cd build
|
||||||
cmake ..
|
cmake ..
|
||||||
@@ -87,7 +87,7 @@ tint2 is a simple panel/taskbar made for modern X window managers. It was specif
|
|||||||
|
|
||||||
## Demos
|
## Demos
|
||||||
|
|
||||||
* 0.13.1: [Compact panel, separator, color gradients](https://gitlab.com/o9000/tint2/wikis/whats-new-0.13.1.0.gif)
|
* [Compact panel, separator, color gradients](https://gitlab.com/o9000/tint2/wikis/whats-new-0.13.0.gif)
|
||||||
* 0.12.4: [Executor](https://gitlab.com/o9000/tint2/wikis/whats-new-0.12.4.gif)
|
* [Executor](https://gitlab.com/o9000/tint2/wikis/whats-new-0.12.4.gif)
|
||||||
* 0.12.3: [Mouse over effects](https://gitlab.com/o9000/tint2/wikis/whats-new-0.12.3.gif)
|
* [Mouse over effects](https://gitlab.com/o9000/tint2/wikis/whats-new-0.12.3.gif)
|
||||||
* 0.12: [Distribute size between taskbars, freespace](https://gitlab.com/o9000/tint2/wikis/whats-new-0.12.gif)
|
* [Distribute size between taskbars, freespace](https://gitlab.com/o9000/tint2/wikis/whats-new-0.12.gif)
|
||||||
|
|||||||
@@ -199,9 +199,9 @@ pre {
|
|||||||
</style>
|
</style>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<h1 id="latest-stable-release-0-13-1"><span class="md2man-title">Latest</span> <span class="md2man-section">stable</span> <span class="md2man-date">release:</span> <span class="md2man-source">0.13.1</span><a name="latest-stable-release-0-13-1" href="#latest-stable-release-0-13-1" class="md2man-permalink" title="permalink"></a></h1><p>Changes: <a href="https://gitlab.com/o9000/tint2/blob/0.13.1/ChangeLog">https://gitlab.com/o9000/tint2/blob/0.13.1/ChangeLog</a></p><p>Documentation: <a href="manual.html">manual.html</a></p><p>Compile it with (after you install the <a href="https://gitlab.com/o9000/tint2/wikis/Install#dependencies">dependencies</a>):</p><pre class="highlight plaintext"><code>git clone https://gitlab.com/o9000/tint2.git
|
<h1 id="latest-stable-release-0-13-2"><span class="md2man-title">Latest</span> <span class="md2man-section">stable</span> <span class="md2man-date">release:</span> <span class="md2man-source">0.13.2</span><a name="latest-stable-release-0-13-2" href="#latest-stable-release-0-13-2" class="md2man-permalink" title="permalink"></a></h1><p>Changes: <a href="https://gitlab.com/o9000/tint2/blob/0.13.2/ChangeLog">https://gitlab.com/o9000/tint2/blob/0.13.2/ChangeLog</a></p><p>Documentation: <a href="manual.html">manual.html</a></p><p>Compile it with (after you install the <a href="https://gitlab.com/o9000/tint2/wikis/Install#dependencies">dependencies</a>):</p><pre class="highlight plaintext"><code>git clone https://gitlab.com/o9000/tint2.git
|
||||||
cd tint2
|
cd tint2
|
||||||
git checkout 0.13.1
|
git checkout 0.13.2
|
||||||
mkdir build
|
mkdir build
|
||||||
cd build
|
cd build
|
||||||
cmake ..
|
cmake ..
|
||||||
@@ -256,10 +256,10 @@ make -j4
|
|||||||
</ul>
|
</ul>
|
||||||
<h1 id="screenshots">Screenshots<a name="screenshots" href="#screenshots" class="md2man-permalink" title="permalink"></a></h1><h2 id="default-config">Default config:<a name="default-config" href="#default-config" class="md2man-permalink" title="permalink"></a></h2><p><img src="https://gitlab.com/o9000/tint2/uploads/948fa74eca60864352a033580350b4c3/Screenshot_2016-01-23_14-42-57.png" alt="Screenshot_2016-01-23_14-42-57"></p><h2 id="various-configs">Various configs:<a name="various-configs" href="#various-configs" class="md2man-permalink" title="permalink"></a></h2><p><img src="https://gitlab.com/o9000/tint2/wikis/screenshot.png" alt="screenshot"></p><h2 id="demos">Demos<a name="demos" href="#demos" class="md2man-permalink" title="permalink"></a></h2>
|
<h1 id="screenshots">Screenshots<a name="screenshots" href="#screenshots" class="md2man-permalink" title="permalink"></a></h1><h2 id="default-config">Default config:<a name="default-config" href="#default-config" class="md2man-permalink" title="permalink"></a></h2><p><img src="https://gitlab.com/o9000/tint2/uploads/948fa74eca60864352a033580350b4c3/Screenshot_2016-01-23_14-42-57.png" alt="Screenshot_2016-01-23_14-42-57"></p><h2 id="various-configs">Various configs:<a name="various-configs" href="#various-configs" class="md2man-permalink" title="permalink"></a></h2><p><img src="https://gitlab.com/o9000/tint2/wikis/screenshot.png" alt="screenshot"></p><h2 id="demos">Demos<a name="demos" href="#demos" class="md2man-permalink" title="permalink"></a></h2>
|
||||||
<ul>
|
<ul>
|
||||||
<li>0.13.1: <a href="https://gitlab.com/o9000/tint2/wikis/whats-new-0.13.1.0.gif">Compact panel, separator, color gradients</a></li>
|
<li><a href="https://gitlab.com/o9000/tint2/wikis/whats-new-0.13.0.gif">Compact panel, separator, color gradients</a></li>
|
||||||
<li>0.12.4: <a href="https://gitlab.com/o9000/tint2/wikis/whats-new-0.12.4.gif">Executor</a></li>
|
<li><a href="https://gitlab.com/o9000/tint2/wikis/whats-new-0.12.4.gif">Executor</a></li>
|
||||||
<li>0.12.3: <a href="https://gitlab.com/o9000/tint2/wikis/whats-new-0.12.3.gif">Mouse over effects</a></li>
|
<li><a href="https://gitlab.com/o9000/tint2/wikis/whats-new-0.12.3.gif">Mouse over effects</a></li>
|
||||||
<li>0.12: <a href="https://gitlab.com/o9000/tint2/wikis/whats-new-0.12.gif">Distribute size between taskbars, freespace</a></li>
|
<li><a href="https://gitlab.com/o9000/tint2/wikis/whats-new-0.12.gif">Distribute size between taskbars, freespace</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
.TH TINT2 1 "2017\-03\-12"
|
.TH TINT2 1 "2017\-03\-12" 0.13.2
|
||||||
.SH NAME
|
.SH NAME
|
||||||
.PP
|
.PP
|
||||||
tint2 \- lightweight panel/taskbar
|
tint2 \- lightweight panel/taskbar
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
# TINT2 1 "2017-03-12"
|
# TINT2 1 "2017-03-12" 0.13.2
|
||||||
|
|
||||||
## NAME
|
## NAME
|
||||||
tint2 - lightweight panel/taskbar
|
tint2 - lightweight panel/taskbar
|
||||||
|
|||||||
13
src/config.c
13
src/config.c
@@ -1178,20 +1178,21 @@ void add_entry(char *key, char *value)
|
|||||||
|
|
||||||
gboolean config_read_file(const char *path)
|
gboolean config_read_file(const char *path)
|
||||||
{
|
{
|
||||||
FILE *fp;
|
FILE *fp = fopen(path, "r");
|
||||||
char line[512];
|
if (!fp)
|
||||||
char *key, *value;
|
|
||||||
|
|
||||||
if ((fp = fopen(path, "r")) == NULL)
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
while (fgets(line, sizeof(line), fp) != NULL) {
|
char* line = NULL;
|
||||||
|
size_t line_size = 0;
|
||||||
|
while (getline(&line, &line_size, fp) >= 0) {
|
||||||
|
char *key, *value;
|
||||||
if (parse_line(line, &key, &value)) {
|
if (parse_line(line, &key, &value)) {
|
||||||
add_entry(key, value);
|
add_entry(key, value);
|
||||||
free(key);
|
free(key);
|
||||||
free(value);
|
free(value);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
free(line);
|
||||||
fclose(fp);
|
fclose(fp);
|
||||||
|
|
||||||
if (!read_panel_position) {
|
if (!read_panel_position) {
|
||||||
|
|||||||
@@ -643,6 +643,7 @@ void execp_timer_callback(void *arg)
|
|||||||
close(pipe_fd[0]);
|
close(pipe_fd[0]);
|
||||||
return;
|
return;
|
||||||
} else if (child == 0) {
|
} else if (child == 0) {
|
||||||
|
fprintf(stderr, "Executing: %s\n", execp->backend->command);
|
||||||
// We are in the child
|
// We are in the child
|
||||||
close(pipe_fd[0]);
|
close(pipe_fd[0]);
|
||||||
dup2(pipe_fd[1], 1); // 1 is stdout
|
dup2(pipe_fd[1], 1); // 1 is stdout
|
||||||
|
|||||||
@@ -26,6 +26,7 @@
|
|||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
#include <strings.h>
|
||||||
|
|
||||||
static gint compare_strings(gconstpointer a, gconstpointer b)
|
static gint compare_strings(gconstpointer a, gconstpointer b)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -269,10 +269,6 @@ const char *signal_name(int sig)
|
|||||||
return "SIGVTALRM: Virtual alarm clock (4.2 BSD).";
|
return "SIGVTALRM: Virtual alarm clock (4.2 BSD).";
|
||||||
case SIGPROF:
|
case SIGPROF:
|
||||||
return "SIGPROF: Profiling alarm clock (4.2 BSD).";
|
return "SIGPROF: Profiling alarm clock (4.2 BSD).";
|
||||||
case SIGWINCH:
|
|
||||||
return "SIGWINCH: Window size change (4.3 BSD, Sun).";
|
|
||||||
case SIGIO:
|
|
||||||
return "SIGIO: Pollable event occurred (System V) / I/O now possible (4.2 BSD).";
|
|
||||||
// case SIGPWR: return "SIGPWR: Power failure restart (System V).";
|
// case SIGPWR: return "SIGPWR: Power failure restart (System V).";
|
||||||
case SIGSYS:
|
case SIGSYS:
|
||||||
return "SIGSYS: Bad system call.";
|
return "SIGSYS: Bad system call.";
|
||||||
|
|||||||
@@ -63,7 +63,7 @@ target_link_libraries( tint2conf ${X11_T2C_LIBRARIES}
|
|||||||
add_definitions( -DINSTALL_PREFIX=\"${CMAKE_INSTALL_PREFIX}\" )
|
add_definitions( -DINSTALL_PREFIX=\"${CMAKE_INSTALL_PREFIX}\" )
|
||||||
add_definitions( -DLOCALEDIR=\"${CMAKE_INSTALL_FULL_LOCALEDIR}\" )
|
add_definitions( -DLOCALEDIR=\"${CMAKE_INSTALL_FULL_LOCALEDIR}\" )
|
||||||
add_definitions( -DGETTEXT_PACKAGE=\"tint2conf\" )
|
add_definitions( -DGETTEXT_PACKAGE=\"tint2conf\" )
|
||||||
set_target_properties( tint2conf PROPERTIES COMPILE_FLAGS "-Wall -pthread -std=c99" )
|
set_target_properties( tint2conf PROPERTIES COMPILE_FLAGS "-Wall -pthread -std=c11" )
|
||||||
set_target_properties( tint2conf PROPERTIES LINK_FLAGS "-pthread" )
|
set_target_properties( tint2conf PROPERTIES LINK_FLAGS "-pthread" )
|
||||||
|
|
||||||
add_subdirectory(po)
|
add_subdirectory(po)
|
||||||
|
|||||||
@@ -38,13 +38,6 @@ void config_read_file(const char *path)
|
|||||||
background_create_new();
|
background_create_new();
|
||||||
gradient_create_new(GRADIENT_CONFIG_VERTICAL);
|
gradient_create_new(GRADIENT_CONFIG_VERTICAL);
|
||||||
|
|
||||||
FILE *fp;
|
|
||||||
char line[512];
|
|
||||||
char *key, *value;
|
|
||||||
|
|
||||||
if ((fp = fopen(path, "r")) == NULL)
|
|
||||||
return;
|
|
||||||
|
|
||||||
config_has_panel_items = 0;
|
config_has_panel_items = 0;
|
||||||
config_has_battery = 0;
|
config_has_battery = 0;
|
||||||
config_battery_enabled = 0;
|
config_battery_enabled = 0;
|
||||||
@@ -54,14 +47,21 @@ void config_read_file(const char *path)
|
|||||||
no_items_systray_enabled = 0;
|
no_items_systray_enabled = 0;
|
||||||
no_items_battery_enabled = 0;
|
no_items_battery_enabled = 0;
|
||||||
|
|
||||||
while (fgets(line, sizeof(line), fp) != NULL) {
|
FILE *fp = fopen(path, "r");
|
||||||
if (parse_line(line, &key, &value)) {
|
if (fp) {
|
||||||
add_entry(key, value);
|
char* line = NULL;
|
||||||
free(key);
|
size_t line_size = 0;
|
||||||
free(value);
|
while (getline(&line, &line_size, fp) >= 0) {
|
||||||
|
char *key, *value;
|
||||||
|
if (parse_line(line, &key, &value)) {
|
||||||
|
add_entry(key, value);
|
||||||
|
free(key);
|
||||||
|
free(value);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
free(line);
|
||||||
|
fclose(fp);
|
||||||
}
|
}
|
||||||
fclose(fp);
|
|
||||||
|
|
||||||
finalize_gradient();
|
finalize_gradient();
|
||||||
finalize_bg();
|
finalize_bg();
|
||||||
|
|||||||
Reference in New Issue
Block a user