Unsolved Basic problem of main.cpp
-
This post is deleted! -
@Nafab213 said in Basic problem of main.cpp:
#include "ui_fenprincipale.h"
You should have
#include "fenprincipale.h"
in your main.cpp file
-
@kenchan
Everything is working now but I have another problem.
In the Qt Designer, I put a File left and vertical file and an Edit toolbar on the top left but it does not take compilation. When I leave the file and return to the file the file toolbar returns to the top left side.
How to write define the modification of the position and the size of my toolbar.
I'm sending you an image to show you.The File Toolbar is on the left
The toolbar Edition is in the middle but I want them defensively in the following order:
ToolbarLong Vertical File
ToolbarEdition Up Horizontal
Can I help? -
Not sure just by looking at that picture. They look to be the correct orientation to me. Is the horizontal one actually docked at the top, or is it floating?
You can restrict where they can dock, that might help. -
@kenchan said in Basic problem of main.cpp:
Not sure just by looking at that picture. They look to be the correct orientation to me. Is the horizontal one actually docked at the top, or is it floating?
You can restrict where they can dock, that might help.How can I restrict their access?
Explain to me .... -
Click on the toolbar in the object list on the right hand side of the Design screen.
look at the properties for the QToolBar object at the bottom of the property list.
Check the allowedAreas that you want to restrict the toolbars docking to. -
Hi
The docking places looks like this
so i think you can only place them like
and not like
-
@mrjj
Thanks for the advice but I decided to put all the toolbar up and horizontal.
Now I have another question ..On my main page there are two buttons.
If we click on the button 1
I would like a table to appear instead of the centralwidget of my window (I intend to create the new Qwidget class called TableauCene). The button 1 will be connected to the slot (showcene) which will display as centralwidget Tableaucene.If we click on the Boutton 2
I would like a table to appear instead of the centralwidget of my window (I intend to create the new Qwidget class called TableauCenep). Button 2 will be connected to the slot (showcenep) which will display as the tableapple centralwidget.How can I program slots "showcene" and "showcenep"?
Thanks for your help.... -
@kenchan
Thanks for the advice but I decided to put all the toolbar up and horizontal.
Now I have another question ..
On my main page there are two buttons.
If we click on the button 1
I would like a table to appear instead of the centralwidget of my window (I intend to create the new Qwidget class called TableauCene). The button 1 will be connected to the slot (showcene) which will display as centralwidget Tableaucene.If we click on the Boutton 2
I would like a table to appear instead of the centralwidget of my window (I intend to create the new Qwidget class called TableauCenep). Button 2 will be connected to the slot (showcenep) which will display as the tableapple centralwidget.How can I program slots "showcene" and "showcenep"?
Thanks for your help.... -
Salut,
Have a look at QStackedWidget or QTabWidget, they are commonly use for the things you've described.