Search found 223 matches

by DenDev
Thu Mar 23, 2017 6:24 pm
Forum: Platform Related Issues
Topic: wxExecute: Unicode arguments on Linux, how to?
Replies: 7
Views: 1226

Re: wxExecute: Unicode arguments on Linux, how to?

I've had some more time to test this issue and wx version 3.1 has fixed the issue, marking as solved :)
by DenDev
Sat Mar 18, 2017 12:11 pm
Forum: Platform Related Issues
Topic: wxExecute: Unicode arguments on Linux, how to?
Replies: 7
Views: 1226

Re: wxExecute: Unicode arguments on Linux, how to?

I have tried to upgrade wx to 3.1.0 and it seems to have solved the issue :)
by DenDev
Fri Mar 17, 2017 6:33 pm
Forum: Platform Related Issues
Topic: wxExecute: Unicode arguments on Linux, how to?
Replies: 7
Views: 1226

Re: wxExecute: Unicode arguments on Linux, how to?

AFAIK Linux uses UTF-8 on the command line. Trace into the wxExecute call and see what it does. https://github.com/wxWidgets/wxWidgets/blob/master/src/unix/utilsunx.cpp#L562 It converts the command line into char** and executes the command using "execvp": https://linux.die.net/man/3/execvp I cannot...
by DenDev
Fri Mar 17, 2017 4:30 pm
Forum: Platform Related Issues
Topic: wxExecute: Unicode arguments on Linux, how to?
Replies: 7
Views: 1226

Re: wxExecute: Unicode arguments on Linux, how to?

The formatters are not part of the problem. This example does not work on Linux (works fine on Windows, though): wxString cmd = "/usr/bin/program"; cmd += " \"/home/me/Skæg.ext\""; wxExecute(cmd, wxEXEC_ASYNC | wxEXEC_MAKE_GROUP_LEADER, m_Process); P.S: Executing the command in a terminal (on Linux)...
by DenDev
Fri Mar 17, 2017 3:25 pm
Forum: Platform Related Issues
Topic: wxExecute: Unicode arguments on Linux, how to?
Replies: 7
Views: 1226

wxExecute: Unicode arguments on Linux, how to?

What must I do to be able to execute a program with a path containing unicode characters as argument? The following will fail: wxString cmd = wxString::Format("\"%s\" \"%s\"", "/usr/bin/program", "/home/me/Skæg.ext"); wxExecute(cmd, wxEXEC_ASYNC | wxEXEC_MAKE_GROUP_LEADER, m_Process); But if I renam...
by DenDev
Thu Dec 01, 2016 6:42 pm
Forum: C++ Development
Topic: Why is wxFontInfo incomplete ?
Replies: 2
Views: 1086

Re: Why is wxFontInfo incomplete ?

wxFontInfo is just a helper class which can be used to more convenient (or read friendly) font creation, like this: wxFont f = new wxFont(wxFontInfo(18).Bold().Underlined().FaceName("Helvetica")); You cannot access the private fields because they are only temporary storage for parameters. The functi...
by DenDev
Wed Oct 26, 2016 2:40 pm
Forum: C++ Development
Topic: Questions regarding threads in wxWidgets
Replies: 3
Views: 580

Re: Questions regarding threads in wxWidgets

You should not update UI-elements from threads (please repeat this inside your head 1000 times!). You should post messages from the threads to the main message loop in order to update the grid. In order to prevent multiple thread accessing the same code / memory at once you should use a wxCriticalSe...
by DenDev
Sat Sep 10, 2016 3:25 pm
Forum: C++ Development
Topic: Time difference
Replies: 3
Views: 565

Re: Time difference

Try this: int64_t wxDateTimeToMillis(wxDateTime dt) { int64_t res = dt.GetHour() * 60; res = (res + dt.GetMinute()) * 60; return ((res + dt.GetSecond()) * 1000) + dt.GetMillisecond(); } int64_t DifferenceInMillis(wxDateTime t1, wxDateTime t2) { return wxDateTimeToMillis(t1) - wxDateTimeToMillis(t2);...
by DenDev
Tue Sep 06, 2016 5:45 pm
Forum: Platform Related Issues
Topic: Issues with wxStaticBoxSizer (GTK build on KDE)
Replies: 11
Views: 1774

Re: Issues with wxStaticBoxSizer (GTK build on KDE)

Hi, DenDev, It is possible that KDE uses a GTK theme that is broken on Linux Mint. I vaguely remember that there was a "not so recent" post to wx-dev/wx-user about theme issue on Linux Mint specifically. Can you try to change a theme of the KDE and try again? Thank you. Bulls eye! The "oxygen-gtk" ...
by DenDev
Mon Sep 05, 2016 7:10 pm
Forum: Platform Related Issues
Topic: Issues with wxStaticBoxSizer (GTK build on KDE)
Replies: 11
Views: 1774

Re: Issues with wxStaticBoxSizer (GTK build on KDE)

A static box is not generic, it is a different control on Windows and OSX and Linux. The wxStaticBoxSizer is a sizer utilizing a static box control. The issue might be related to bad font size calculation - but since my build of wx is GTK 2 I do not think it is related to GTK 3 . I think the issue i...
by DenDev
Mon Sep 05, 2016 6:10 pm
Forum: Platform Related Issues
Topic: Issues with wxStaticBoxSizer (GTK build on KDE)
Replies: 11
Views: 1774

Re: Issues with wxStaticBoxSizer (GTK build on KDE)

It has nothing to do with Windows, so of course the issue is not present there. I'm using a default GTK2 build on Linux Mint 17.3 KDE. I've tried to test the sample application on another computer running Debian Jessie with the same KDE desktop installed. The problem was not present there but the ap...
by DenDev
Mon Sep 05, 2016 1:36 pm
Forum: Platform Related Issues
Topic: Issues with wxStaticBoxSizer (GTK build on KDE)
Replies: 11
Views: 1774

Re: Issues with wxStaticBoxSizer (GTK build on KDE)

Can't make it any lesser than the attached Code::Blocks project.
by DenDev
Mon Sep 05, 2016 12:51 pm
Forum: Platform Related Issues
Topic: Issues with wxStaticBoxSizer (GTK build on KDE)
Replies: 11
Views: 1774

Re: Issues with wxStaticBoxSizer (GTK build on KDE)

It is created using Code::Blocks / wxSmith, copied from TestDialog.cpp: wxStaticBoxSizer* StaticBoxSizer2; wxFlexGridSizer* FlexGridSizer1; wxBoxSizer* BoxSizer1; wxStaticBoxSizer* StaticBoxSizer1; Create(parent, id, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxDEFAULT_DIALOG_STYLE, _T("id"));...
by DenDev
Mon Sep 05, 2016 12:21 pm
Forum: Platform Related Issues
Topic: Issues with wxStaticBoxSizer (GTK build on KDE)
Replies: 11
Views: 1774

Re: Issues with wxStaticBoxSizer (GTK build on KDE)

Trying to add image 2..
by DenDev
Mon Sep 05, 2016 12:06 pm
Forum: Platform Related Issues
Topic: Issues with wxStaticBoxSizer (GTK build on KDE)
Replies: 11
Views: 1774

Issues with wxStaticBoxSizer (GTK build on KDE)

I've run into an odd issue related to the usage of wxStaticBoxSizer's in a GTK build running on Linux Mint 17.3 KDE 64 bit. The first attached image shows a dialog using the sizer as it looks when opened. As you can see the header of the static box is a bit squashed. The dialog can be resized and if...