commit 47fc4b95d6d86338673ee048b335af087e0f1696
parent 668c8a7c3c5d1591159fdf7932b608a0c613be36
Author: Alexander Kojevnikov <alexander@kojevnikov.com>
Date: Tue, 21 Aug 2012 10:15:24 -0700
Bump the version number + tidy
Diffstat:
4 files changed, 13 insertions(+), 8 deletions(-)
diff --git a/configure.ac b/configure.ac
@@ -1,4 +1,4 @@
-AC_INIT([spek],[0.7])
+AC_INIT([spek],[0.8.0])
AC_CONFIG_SRCDIR([src/spek.cc])
AC_CONFIG_HEADERS([config.h])
AM_INIT_AUTOMAKE([1.11.1 foreign no-dist-gzip dist-xz])
diff --git a/src/spek-pipeline.c b/src/spek-pipeline.c
@@ -143,7 +143,8 @@ void spek_pipeline_start(struct spek_pipeline *p)
}
}
-void spek_pipeline_close(struct spek_pipeline *p) {
+void spek_pipeline_close(struct spek_pipeline *p)
+{
if (p->has_reader_thread) {
p->quit = true;
pthread_join(p->reader_thread, NULL);
@@ -188,7 +189,8 @@ void spek_pipeline_close(struct spek_pipeline *p) {
free(p);
}
-static void * reader_func (void *pp) {
+static void * reader_func(void *pp)
+{
struct spek_pipeline *p = pp;
p->has_worker_thread = !pthread_create(&p->worker_thread, NULL, &worker_func, p);
@@ -243,7 +245,8 @@ static void reader_sync(struct spek_pipeline *p, int pos)
pthread_mutex_unlock(&p->worker_mutex);
}
-static void * worker_func (void *pp) {
+static void * worker_func(void *pp)
+{
struct spek_pipeline *p = pp;
int sample = 0;
diff --git a/src/spek-spectrogram.cc b/src/spek-spectrogram.cc
@@ -43,7 +43,7 @@ enum
BANDS = NFFT / 2 + 1,
LPAD = 60,
TPAD = 60,
- RPAD = 80,
+ RPAD = 90,
BPAD = 40,
GAP = 10,
RULER = 10,
@@ -184,6 +184,8 @@ void SpekSpectrogram::render(wxDC& dc)
int normal_height = dc.GetTextExtent(wxT("dummy")).GetHeight();
dc.SetFont(large_font);
int large_height = dc.GetTextExtent(wxT("dummy")).GetHeight();
+ dc.SetFont(small_font);
+ int small_height = dc.GetTextExtent(wxT("dummy")).GetHeight();
// Clean the background.
dc.Clear();
@@ -197,11 +199,11 @@ void SpekSpectrogram::render(wxDC& dc)
TPAD - 2 * GAP - normal_height - large_height
);
int package_name_width = dc.GetTextExtent(package_name + wxT(" ")).GetWidth();
- dc.SetFont(normal_font);
+ dc.SetFont(small_font);
dc.DrawText(
wxT(PACKAGE_VERSION),
w - RPAD + GAP + package_name_width,
- TPAD - 2 * GAP - 2 * normal_height
+ TPAD - 2 * GAP - normal_height - small_height
);
if (this->image.GetHeight() > 1) {
diff --git a/src/spek-window.cc b/src/spek-window.cc
@@ -119,7 +119,7 @@ SpekWindow::SpekWindow(const wxString& path) :
info_bar, -1, wxArtProvider::GetBitmap(wxT("gtk-close")),
wxDefaultPosition, wxDefaultSize, wxNO_BORDER);
button->Connect(wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler(SpekWindow::on_close));
- info_sizer->Add(button, 0, 0);
+ info_sizer->Add(button, 0, wxALIGN_CENTER_VERTICAL);
info_bar->SetSizer(info_sizer);
sizer->Add(info_bar, 0, wxEXPAND);