QT Style Comments (Intellisense?) - c++

I noticed in 2.1 of QTCreator, that they now have a sort of intellisense similar to that of Visual Studio. I know intellisense is Microsoft's name for this concept of the helpful tooltip that pops up giving you a description of the method, parameters etc so i don't know what this is actually called. Does anyone know how to add these type of pop-up comments to methods and classes in QT?
Again to clarify what i'm talking about are like javadoc comments or the "///" in C#. I'm hoping the devs of QT have a way for the users to make their own comments.
Thanks for the help,
Jec

I've been wanting to do this as well.
I found this thread over on qtCentre.org where someone has integrated their own docs into the QT Creator Tooltips. I haven't tested it myself, but it sounds reasonable:
http://www.qtcentre.org/archive/index.php/t-40324.html?s=98d48c38547da14b0725e5106d83c315
To use your own documentation in Qt
Assistant (and in Qt Creator help as
well) you need to create Qt Compressed
Help file (.qch
(http://doc.qt.nokia.com/4.7/assistant-custom-help-viewer.html#displaying-custom-documentation))
and register it in Assistant and
Creator. Doxygen has several tools
exactly for Qt. There are tags in it's
config file, that help you to create
the documentation exactly the way you
need. E.g. with GENERATE_QHP tag you
can make it create the ready qhp
(http://doc.qt.nokia.com/4.7/assistant-custom-help-viewer.html#creating-a-custom-help-collection-file)
(Qt Help Project) file (you need this
to generate the .qch). If you don't
need to edit this file manually before
creating the .qhc, you can set the
value of QHG_LOCATION tag to the
location of your qhelpgenerator.exe
(usually it's here (in Windows):
/mingw/bin/qhelpgenerator.exe)
and it will generate the ready
documentation. Register it in Qt
Assistant (optional) and Creator and
you're done. After this all your
documented types, functions, members,
etc. will have the tooltip with F1
button hint. And of course pushing F1
will show your documented help for it.

Related

VSIX Project - Properties tool window extension

There might be something wrong with the way I search for things but here is my problem. I'm looking for a way to implement a custom editing tool within the properties tool window in the Visual Studio editor. I've been looking through several documentation references, and they all lead to the use of different assemblies, but I can't get anything to work the way that I want.
First of all, I tried using the UITypeEditor class, with the step-by-step tuto I found here : https://learn.microsoft.com/fr-fr/dotnet/api/system.drawing.design.uitypeeditor?view=net-5.0
The problem I faced was that it only seemed to be working with Winforms projects, and I'm trying to use this with a WPF project.
Afterwards, I tried following this tutorial, in order to create a project template : https://learn.microsoft.com/en-us/visualstudio/extensibility/creating-a-basic-project-system-part-1?view=vs-2019
This has led me to think that the methods used in the tutorial might have been either deprecated or improved with the used of AsyncPackages instead of ProjectPackages, and the appearance of the Microsoft.VisualStudio.Shell.Flavor assembly that seem to render useless the ProjectNode class (it doesn't even show up anymore, the method has been replaced with a void).
The last bit I tried exploring was the use of the ProjectSystem, as documented here : https://github.com/microsoft/VSProjectSystem
It was actually worse because I couldn't get it to work like I wanted, the project type I was creating could not register C# files and I wasn't able to add new classes (I might need to dig a bit deeper here but I don't know where to look).
So basically, I'm looking for help to extend the properties tool window, through an editor within the window, or a modal window opened by clicking on an ellipsis button in the properties window.
Thank you for reading this, if you have any info, I'm very interested.
I've actually found a thread leading to what I was trying to do here. This tutorial leads to a way to implement a customized editor, either inline, extended or in another dialog window. This was the thing I needed, and with a few tweaks I managed doing what I wanted.

How to create desktop application using fully customized UI?

Have a look at this figure below, which is a Quick Book Enterprise Solution 2014
Judging by its interface (not its DLL), I don't think you can easily guess with what platform/language does the above application was created. Qt? .NET? Java? It has its own border, custom menu, ... etc. In a simple wording, "it has totally customized UI that make it stand from the rest".
What do we need to be able to create this kind of application with fully customized UI? And what if I add cross platform aspect in this application? Different customized widgets in different OSes... but maintaining the same level of UI appearance...
I have previous experience with Qt, .. but I am not sure Qt can do this.. or is it?
For instance, you can write your own plugin similar to the existing qt style plugins.
Here, you can find an example how to write widget based style plugins with Qt 5:
QtWidgets 5.0: Style Plugin Example
You would work with the QStylePlugin plugin interface.
If you are looking into a bit more modern solution, you may find this qml style and theme support documentation useful.

Using c++ how to show overlay icon in finder mac osx

Recently we developed a MAC installer(.dmg). This is developed in c++ and QT. We had a hard requirement to show overlay icons on the files in the finder like how CVS/Dropbox shows sync status on files.
My question is exactly similar to below post. I understand that, if we try to show overlay icons in finder, MAC app store doesn't allow my app to be there. I am fine with this, my users will download the app from the website.
How can i add icon overlay in finder?
Am pretty much new to MAC and c++ also, Can you please provide me suggestion or solution in c++ in detailed.
I know this answer is somewhat late, but better than no answer, isn't it?!
Dropbox uses an open source framework called mach_inject. Originally developed by Jonathan Rentzsch, and known as Mach_Star, it allows code injection into applications.
Dropbox use this to inject into the OSX Finder application. If you Google for "Dropbox mach_inject" you'll find various references to this. Although it's not exactly what you want, there's also a project here which also injects into Finder, but to add menu items. You should be able to use that as reference.

How to develop nice-looking, visually modern applications in QT?

I'm wondering how to develop visually modern, with attractive GUI applications in QT. When I run QT Creator and start new project, the GUI looks very basic and "pure", just like simple win32 apps. But look for example at Allegorithmic Substance Designer 2, where GUI looks somehow similar to WPF. There are many other applications with nice-looking GUI. So, the question is: how to do this? Is there any extension/library to QT, which provide richer GUI experience? Or it must be developed from scratch? Thanks for replies in advance.
As well as Nano's answer, I think it would be worth your while to search around for any Qt stylesheets others have made.
For example, this one that mimics Microsoft Office.
Unfortunately, there doesn't seem to be very many of them available.
I found these useful links, some of whose links may give some ideas:
Qt Stylesheet Snippet Repository
Another idea might be to search for example qml files in Google Code Search. This search for .qml files has plenty of hits. Before using any of them, you would obviously need to check its license.
Have you tried Nokia's Qt Creator? If you're looking for something "similar" to WPF I assume you're referring to its declarative nature, QML being XAML's counterpart in such regard.

Help Integration in Qt/C++ Application

I am using Qt 4.6 so do C++.
I have a User Manual (.chm) for my application which has the help required for the users to run the application. Now I want this help to be integrated into my application, so that when the user selects for help from the application, the user manual will be opened with the corresponding help page displayed. In this way I can make use of the already available manual and users will find easy to probe through the document. (since it is familiar)
The user manual file is in the .chm format which has corresponding search keywords, which can be used to display the corresponding page when selected from the application. Just similar to F1 help in any of the windows application.
Is it possible to do this in Qt or C++? Or
What are the other ways through which the help can be integrated in the application?
Any pointers regarding this are welcome..
Yes, it's possible. The help system infrastructure was designed to integrate with normal Win32 development in Visual Studio, but this is not technically necessary. Basically you just call HtmlHelp(GetDesktopWindow(), "Yourhelp.chm", HH_HELP_CONTEXT, IDYourCurrentContext);.
The more Qt way of Help Integration can also be done which is as follows.
The chm files are always opened by the hh.exe
So,
QProcess::execute("hh.exe D:/Manual.chm");
can be used to open the Manual.chm file from the application.
The command
QProcess::execute("hh.exe D:/Manual.chm::page1.htm");
will open the chm file with the page1.htm loaded. This will be helpful to load a specific help page in the chm file.
The only thing we must be aware in this approach is that we must have known the file name of the web pages (here page1.htm) previously..
Hope this one also helps... :)
QDesktopServices::openUrl() would be even more Qt way. Then you do not need to specify hh.exe but rely instead on the system file associations to use proper application. Hence - portability, the key thing behind Qt stuff.
try using libCHMxx or CHM lib along with Qt help system (see this sample)