When I add " import Qt.labs.platform " and remove the Button it works fine on android but
when the button is not removed i get this error "W libuntitled30_arm64-v8a.so: QQmlApplicationEngine failed to load component
W libuntitled30_arm64-v8a.so: qrc:/untitled30/main.qml:116:5: Cannot assign to non-existent property "background"
W libuntitled30_arm64-v8a.so: exit app 0"
When i add 'QT += widgets' in .pro file (with the Button not removed) the error does not appear, but the Messagedialog does not respond to dismiss the dialog.
It seem like Qt.labs.platform does not work with other import statements
@SGaist Yes in fact I over simplified thing in my report of this issue.
The code I said was in the ctor is actually called from my onInitialise() mf which is called from showEvent():
void DeepSkyStacker::showEvent(QShowEvent* event)
{
if (!event->spontaneous())
{
if (!initialised)
{
initialised = true;
onInitialise();
}
}
// Invoke base class showEvent()
return Inherited::showEvent(event);
}
David
@tataeress I just tried and it works ok. Added a function call, changed some parameters around, modified member values etc.
Not all types of changes are supported: Supported Code Changes (C++).
What kind of chang are you trying to make for example?
Hello this is Gulshan Negi
Well, Squish is a software tool used for automated GUI testing of applications developed for various platforms such as Windows, Linux, macOS, and embedded systems. Squish offers several certification courses for software testers, developers, and managers to enhance their skills in automating GUI testing using Squish. These courses include:
Squish Certified Tester (SCT)
Squish Certified Engineer (SCE)
Squish Certified Manager (SCM)
The courses are designed to provide hands-on experience, theoretical knowledge, and certification upon completion.
Hope it will help.
@mjsmithers said in Subclassing QThread and signals/slots?:
Thanks. Yep, I'm fine with QThread allowing signals and slots, but I think a compile warning is warranted when subclassing and the subclass has signals and slots.
What warning? Did you remember to put the required Q_OBJECT macro in?
I didn't like too much the idea of using the private module, so this is how I implemented it: https://github.com/carlonluca/lqtutils/blob/master/lqtutils_ui.h#L55. Uses Objective-C++ on iOS and JNI on Android. More info: https://bugfreeblog.duckdns.org/2023/01/qt-qml-cutouts.html.
Perhaps I do not get term "virtual" when the device is actually implemented in hardware.
What I really need is to be able to code ( not in command - using C /C++ code ) RS232 /EIA 232 communication setup for Bluetooth.
What I have now is Bluetooth ( using bluez library ) "rfcomm" . Rfcomm takes any data . it does not care.
What I am missing is the "front end " the actual setting of RS232 /EIA 232 which requires implementing "serial port" - and that part of the code is missing in Bluetooth examples- the only note I get is " add virtual serial port to the code" .
Before I can actually use Bluetooth I have to have RS232 /EIA 232 configured , so if I skip the "virtual" term - my code need to have "serial port " implemented before I can pass the data to the local Bluetooth (hardware) adapter.
I imagine this setup would be similar to passing audio using Bluetooth - there has to be a source / physical form of the audio first...- hence I need "serial port" .
@KenAppleby-0 said in No Console Output To Terminal on Windows When Using CMake:
So the answer seems to be to not have either WIN32 in the add_executable or WIN32_EXECUTABLE ON in the set_target_properties?
Yes - as the documentation states WIN32 creates an application with WinMain() as entry point and therefore has no console.
Since it's a c++ class you can derive from it like for any other class.
But it won't help you since QPushButton instantiates a QStyleOptionButton internally, not your class.
I also don't see why deriving from QStyleOptionButton should be needed.
You want to install Qt 5.15 etc. but you have an installer for Qt 4.5.1.
Qt 4 seriously predates Windows 10, so it is probably unsurprising that there may be issues.
Try the current installer from qt.io or your commercial account if that is appropriate.
git branch dev creates a branch but does not switch your working copy to that branch. Follow up with one of git switch dev or git checkout dev.
You can create a branch and switch your working copy in one action git checkout -b dev
Edit: Actually @JKSH is closer to answering the particular issue.
@micha_eleric
Hide what, instead of delete? The OP is asking a common question about how to have a button against each row, to delete that row from the database, or similar functionality.
The *_p.h files are the declaration of a private implementation, PIMPL, of the related class e.g., qlocale.h and qlocale_p.h. PIMPL is used for varied reasons, for example:
Make maintaining binary compatibility across versions easier. So, for example, code written and linked against Qt 5.12 can use a Qt 5.15 library set even if the internal implementation of some classes is wildly different.
Make implementation opaque, with only a public API header published with a binary library.
Qt does both. Have a read here for example.
@SGaist I changed the desing: Now QPushButtons are displayed in the QScrollArea, so the Button with the ssid and the other elements (The line to write a password, the button to connect to a network) are shown separately. With these simple changes, the code I wrote before works like a charm! True, It wasn't what I originally intended, but I realized that it's far better due to the circumstances where this app is going to be used.
Thanks for your time and your help!
@paulf I have exactly the same problem. I even removed Qt and re-installed it all to no avail. I assume that it is something that Creator uses (Python functions or something), but I have no idea of how to find out what it might be.
@JKSH said in A problem that has been bothering me for 7 months:
This was in your error log.
To fix it, install the Qt Positioning module.
Following this, I fix it! Thanks
Ensure you build a debug version of your project:
then run the program in the debugger:
generate the crash:
then look at the debugger panes at the bottom of your screen. The left panel is the back trace (yours will be longer). Right-click to copy the text:
Select the top-most line in the back trace that is in your code. There is a panel that shows the variables in scope at the time of the call selected.
@AnneRanch said:
how do I DELETE the TEST menu ?
Right click on it in the object tree and select "Remove".
I want to delete "menuBluetooth and start over
Same. Right click on it in the object tree and select "Remove".
That's how you delete menus. To delete an action right click on it in the actions window and select "Delete" (a bit of option naming inconsistency but whatever).
add new menu "Bluuetooth" .
All I am getting is "TYPE here " and no way to say "save it " .
Double click on "Type Here", type the text you want to see and hit enter. If you do that on a menu bar it will add a menu. If you do that inside a menu it will add an action.
There is no obvious "drag and drop" ...
Drag & drop is for existing actions. They are listed in the actions window. You dag it from there and drop it in the preview window of your form onto the menu you want to put it in.
If you want to create a new action that's not yet on the list you can use the "Type Here" method mentioned above. That will create a new action and add it to the menu. Alternatively you can create an action by clicking the "New" icon on the toolbar of the actions window and then drag&drop it onto a menu.
To add to SGaist' response, below is an example of Q_ENUM in a struct with Q_GADGET:
struct Message
{
Q_GADGET
public:
enum Status {
Ready,
Loading,
Error
};
Q_ENUM(Status)
};
This precludes using signals and slots within the struct, is a lightweight solution for properties or unit test arguments. This works as far back as Qt 5.5.
https://stackoverflow.com/questions/4507864/how-to-customize-the-title-bar-of-a-qt-app-through-qt-stylesheet
Maybe you have to customize title bar. That means to create your own one.
Hi,
Determine on enter whether further processing shall be done.
And for the move, your entire widget might not be a target for dropping or might change the outcome based on some condition.
@bee65 said in Android ANR Deadlock in QtAccessibilityDelegate:
Looks like the same issue.
I am rolling out an update that adds
qputenv("QT_ANDROID_DISABLE_ACCESSIBILITY", "1");
in my app's main function before the construction of the QGuiApplication. I will know in a month or so whether this avoids the problem.
See https://bugreports.qt.io/browse/QTBUG-102168
So far, I have had zero ANRs in the new update with this change, rolled out to about 3000 users.
Since it's a new process, I think the environment should be clean. The simplest is to create a test application where you mix both as you intend to do in your main application.