Search found 98 matches

by Everydaydiesel
Wed Feb 13, 2019 4:53 pm
Forum: C++ Development
Topic: Selecting Multiple Items In A wxListBox Without Having To Manually Press Ctrl
Replies: 11
Views: 127

Re: Selecting Multiple Items In A wxListBox Without Having To Manually Press Ctrl

I already have wxLB_MULTIPLE and I CAN hold the ctl key down and select multiple items. My question is, how can I create this functionality WITHOUT having to hold ctl. Platform, wxWidgets version? With wxLB_MULTIPLE you should get the behavior you want. I checked with the "widgets" sample under Win...
by Everydaydiesel
Tue Feb 12, 2019 4:57 pm
Forum: C++ Development
Topic: Selecting Multiple Items In A wxListBox Without Having To Manually Press Ctrl
Replies: 11
Views: 127

Re: Selecting Multiple Items In A wxListBox Without Having To Manually Press Ctrl

Thank you for the reply however that does not really help me.

I already have wxLB_MULTIPLE and I CAN hold the ctl key down and select multiple items. My question is, how can I create this functionality WITHOUT having to hold ctl.
by Everydaydiesel
Mon Feb 11, 2019 11:07 pm
Forum: C++ Development
Topic: Selecting Multiple Items In A wxListBox Without Having To Manually Press Ctrl
Replies: 11
Views: 127

Selecting Multiple Items In A wxListBox Without Having To Manually Press Ctrl

Hello,

I have a wxListBox and basically I want to be able to click items and if it is selected then deselect it and if it is deselected then it should be selected.

How can I do this without having to hold down the control key?

Thanks in advance!
by Everydaydiesel
Mon Feb 11, 2019 5:50 pm
Forum: C++ Development
Topic: Multi Threaded Application Wont Exit
Replies: 2
Views: 85

Re: Multi Threaded Application Wont Exit

thank you soooo much
closing the socket, joining the thread and calling event.skip() works!

thanks again
by Everydaydiesel
Mon Feb 11, 2019 3:55 pm
Forum: C++ Development
Topic: Multi Threaded Application Wont Exit
Replies: 2
Views: 85

Multi Threaded Application Wont Exit

I have spent way too much time on this so I am reaching out for help to guys that are much smarter. This is the most simplistic version I can make to recreate this problem. It is a wxwidgets (wxdialog/wxsmith) application but I can run it from the command line so it starts the gui and gives me cout ...
by Everydaydiesel
Thu Oct 04, 2018 9:12 pm
Forum: C++ Development
Topic: Iterating Over All Tree Items in wxTreeCtrl
Replies: 2
Views: 113

Iterating Over All Tree Items in wxTreeCtrl

Hello, I have the following recursive code but the problem is that it does not iterate over the last tree view item. I am unsure why really. void Form::GetAllTreeViewItems(wxTreeCtrl *tv, const wxTreeItemId& tiiCurrent) { wxTreeItemIdValue cookie; wxTreeItemId child = tv->GetFirstChild(tiiCurrent, c...
by Everydaydiesel
Thu Oct 04, 2018 3:27 pm
Forum: C++ Development
Topic: wxImageList invalid use of incomplete type
Replies: 2
Views: 368

Re: wxImageList invalid use of incomplete type

doh. i spent entirely too long on this! Thanks for the help
by Everydaydiesel
Thu Oct 04, 2018 3:14 pm
Forum: C++ Development
Topic: wxImageList invalid use of incomplete type
Replies: 2
Views: 368

wxImageList invalid use of incomplete type

Hello I am trying to add icons to a wxTreeCtrl and I am setting up the wxImageList and get the error error: invalid use of incomplete type 'class wxImageList' wxImageList *imgList; wxBitmap bmps[2]; bmps[0] = wxIcon(BASE_IMAGE_ICON_PATH + "Filetype-jpg-icon.png"); bmps[1] = wxIcon(BASE_IMAGE_ICON_PA...
by Everydaydiesel
Sun Aug 19, 2018 1:25 am
Forum: wxCode
Topic: wxPdfDocument Calculating Text Height
Replies: 1
Views: 1426

wxPdfDocument Calculating Text Height

Hello,

I see a GetStringWidth but I do not see one for height? Am I missing it?


Thanks again!
by Everydaydiesel
Sun Aug 19, 2018 12:51 am
Forum: wxCode
Topic: wxPdfDocument SetAutoPageBreak Not Working
Replies: 3
Views: 1471

Re: wxPdfDocument SetAutoPageBreak Not Working

so if I have a pdf (report) that has 4 columns.

How can I print 4 header labels and then align them with the columns for each row?

Lets say i have a column that starts at 10, 100, 150, and 250.
by Everydaydiesel
Sat Aug 18, 2018 10:30 pm
Forum: wxCode
Topic: wxPdfDocument SetAutoPageBreak Not Working
Replies: 3
Views: 1471

Re: wxPdfDocument SetAutoPageBreak Not Working

thank you!!!


On last question, is there any way I can preview the pdf in a control (like rendering it inside of a wxPanel)
by Everydaydiesel
Sat Aug 18, 2018 8:42 pm
Forum: wxCode
Topic: wxPdfDocument SetAutoPageBreak Not Working
Replies: 3
Views: 1471

wxPdfDocument SetAutoPageBreak Not Working

Hello, I am trying to figure out the SetAutoPageBreak but it seems that I am not using it properly. Even though the loop goes to 250, the pdf document is only one page wxPdfDocument m_pdfDoc; wxPdfFontManager::GetFontManager()->AddSearchPath(wxT("/usr/share/fonts")); m_pdfDoc.SetAutoPageBreak(true,1...
by Everydaydiesel
Fri Aug 17, 2018 3:05 am
Forum: wxCode
Topic: Getting Text Size With wxPdfDocument
Replies: 2
Views: 1472

Re: Getting Text Size With wxPdfDocument

Thank you kind sir! That worked!
by Everydaydiesel
Wed Aug 15, 2018 8:53 pm
Forum: wxCode
Topic: Getting Text Size With wxPdfDocument
Replies: 2
Views: 1472

Getting Text Size With wxPdfDocument

Hello, I am trying to use GetStringWidth() in wxPdfDocument and I was expecting the line drawn to be the same length as the text. Does anyone know what I am doing wrong? string sFilePath = "/home/test/test.pdf"; wxPdfFontManager::GetFontManager()->AddSearchPath(wxT("/usr/share/fonts")); wxPdfDocumen...
by Everydaydiesel
Wed Aug 08, 2018 4:21 am
Forum: C++ Development
Topic: Capturing The Key Event In A wxTextCtrl
Replies: 1
Views: 105

Re: Capturing The Key Event In A wxTextCtrl

to answer my own question txtBaseFilePath->Connect(wxEVT_CHAR, wxCharEventHandler(PathKeyPress)); void PathKeyPress(wxKeyEvent& event) { // Ignore enter key in filename dialog if (event.GetKeyCode() == WXK_RETURN) { wxMessageBox("yes"); return; } // Process all other keys as usual event.Skip(); }