Search found 132 matches

by Kvaz1r
Tue Dec 11, 2018 4:45 pm
Forum: C++ Development
Topic: Full Working Example of a wxGrid
Replies: 15
Views: 2647

Re: Full Working Example of a wxGrid

I mean for example that SetColFormatFloat, it does nothing really usefull and since it is not posible to get and set float values to a cell of the grid it apears complete useless to me. Can somebody posibly explain why such functions exist at all? So to make clear what I would like wxGrid to use fo...
by Kvaz1r
Tue Dec 11, 2018 4:37 pm
Forum: C++ Development
Topic: wxtextctrl setvalue/getvalue confusion
Replies: 7
Views: 587

Re: wxtextctrl setvalue/getvalue confusion

Hello. Not sure that I undesrstand what you want to achieve. Maybe you can provide some example with expected and actual output?
For displaying "compound" number you can join into one string several values with some delimeter.
by Kvaz1r
Thu Dec 06, 2018 4:28 pm
Forum: wxWidgets Development (Russian)
Topic: EVT_TEXT с задержкой. Есть ли такое в wxTextCtrl
Replies: 7
Views: 866

Re: EVT_TEXT с задержкой. Есть ли такое в wxTextCtrl

В документации нет ничего похожего, хотя лично я не вижу смысла добавлять такой редкий кейс в библиотеку.
Можно попробовать обойтись EVT_TEXT_ENTER, если уверены что пользователь нажмет Enter по завершению редактирования.
by Kvaz1r
Mon Nov 26, 2018 11:17 am
Forum: C++ Development
Topic: wxRadioButton event handler
Replies: 1
Views: 125

Re: wxRadioButton event handler

You should marked your radiobuttons as group. For it - to pass style wxRB_GROUP to constructor of first element of group. Documentation . For example: #include <wx/wx.h> const wxWindowIDRef ID_NONEUSERAUTH = wxWindow::NewControlId();; const wxWindowIDRef ID_PASSUSERAUTH = wxWindow::NewControlId();; ...
by Kvaz1r
Tue Nov 13, 2018 10:16 am
Forum: C++ Development
Topic: [wxMSW][wx3.0.3] How to prevent editing some cells of a wxDataViewListCtrl
Replies: 2
Views: 189

Re: [wxMSW][wx3.0.3] How to prevent editing some cells of a wxDataViewListCtrl

Why not use wxGrid instead wxDataViewListCtrl if you need hard operations with cells? This control provides much more features.
by Kvaz1r
Sat Nov 10, 2018 7:41 am
Forum: C++ Development
Topic: I want to move a wxStaticBitmap from frame to another Dialog, how to do?
Replies: 6
Views: 582

Re: I want to move a wxStaticBitmap from frame to another Dialog, how to do?

lfjking wrote: I don't know the SetContainingSizer what to do and why?
According to documentation:
This normally does not need to be called by user code.

It is called when a window is added to a sizer, and is used so the window can remove itself from the sizer when it is destroyed.
by Kvaz1r
Mon Oct 29, 2018 5:58 pm
Forum: C++ Development
Topic: How to set font for one of toolbutton in wxToolbar?
Replies: 13
Views: 545

Re: How to set font for one of toolbutton in wxToolbar?

Not sure is it really can to be done.

What about method GetControl/1?

Something like

Code: Select all

m_toolBar->FindControl(toolid)->SetFont(ft);
but with all necessary checkings(on NULL).

Though maybe it will work only for controls that was added via AddControl.
by Kvaz1r
Sat Oct 27, 2018 3:48 pm
Forum: wxWidgets Development (Russian)
Topic: No Target! You should use wx-config program for compilation flags!
Replies: 3
Views: 1163

Re: No Target! You should use wx-config program for compilation flags!

Здравствуйте.
Попробуйте решение отсюда - Code::Blocks WxWidget error - No Target! You should use wx-config program for compilation flags?

Но вообще советую спрашивать в англоязычном разделе.
by Kvaz1r
Sat Oct 27, 2018 11:00 am
Forum: C++ Development
Topic: How to catch a left click on a wxSlider thumb
Replies: 8
Views: 374

Re: How to catch a left click on a wxSlider thumb

I've tried the 2 following OnSlider implementations: Code below works for me, try change it for your event: #include <wx/wx.h> class MyFrame : public wxFrame { public: MyFrame() : wxFrame(NULL, wxID_ANY, "Test", wxDefaultPosition, wxSize(600, 400)) { wxBoxSizer* bSizer1 = new wxBoxSizer( wxVERTICAL...
by Kvaz1r
Sat Oct 27, 2018 10:42 am
Forum: C++ Development
Topic: How to catch a left click on a wxSlider thumb
Replies: 8
Views: 374

Re: How to catch a left click on a wxSlider thumb

bertolino wrote: But there is no counterpart to wxEVT_SCROLL_THUMBRELEASE and mouse events are not available for a wxSlider.
They are. Because wxSlider inherit they from wxWindow.
About click events see this SO question - wxWidgets: Detecting click event on custom controls
by Kvaz1r
Fri Oct 26, 2018 4:02 pm
Forum: C++ Development
Topic: wxSpinCtrl problem wxSpinEvent is handled twice
Replies: 18
Views: 803

Re: wxSpinCtrl problem wxSpinEvent is handled twice

I can reproduce issue with this code: #include "wx/wx.h" #include <wx/spinctrl.h> class MyFrame : public wxFrame { public: MyFrame(const wxString& title) : wxFrame(NULL, wxID_ANY, title) { wxBoxSizer* bSizer1 = new wxBoxSizer( wxVERTICAL ); m_spinCtrl1 = new wxSpinCtrl( this, wxID_ANY, wxEmptyString...
by Kvaz1r
Wed Oct 24, 2018 11:30 am
Forum: C++ Development
Topic: wxSharedPtr warnings..... what should i do?
Replies: 1
Views: 425

Re: wxSharedPtr warnings..... what should i do?

First of all warnings it's not errors, so you should be able to compile the source.
But since usually warnings are helpful you could open new issue or try to fix it and open PR.
As far I understand for this case enough to add virtual destructor for class .