Widget accessibility in all applications - aviarc

How do I copy a widget to a place where it will be available for all projects in an installation?

You can make a widget namespace available to all applications by copying it to <aviarc-data>/widgets, and then restarting Aviarc. (This is also the folder where the default widget namespaces com.aviarc.toronto.widget.core* are located.)
If your widget isn't namespaced, copy it to something like <aviarc-data>/widgets/awesome-widget-namespace/1.0.0/widgets/<your-widget>.

Related

LabVIEW Virtual Folder vs Auto-populated Folder

In a LabVIEW project, when should I use virtual folder and when should I use auto-populated folder? Why?
You don't have to use either. Your project could just have a main VI and have everything else handled automatically as a dependency.
Personally, I would suggest viewing the project window as a logical organization tool for your work and say that you should only put the things you actually need or want to access from there.
The conclusion from this is that you should generally not use auto-pop folders, as you don't need that. If you want to see the disk hierarchy, you can go to the files tab in the project window.
You can use virtual folders for your logical organization. For example, you might want to have support files for your builds (like an icon for the EXE) and putting those in a folder cleans up the project. Another example might be that you have a library (like a class) and you want to group subitems in that library into some logical groups. You can create virtual folders inside that library.
The one place where I do use auto-pop. folders is if I have some dynamically loaded VIs or another list of files which are placed in the same folder. Adding that folder to the project as auto-pop allows it to be handled cleanly.
It is your choice. How do you want to manage your files?
For myself, the answer is “never ever use auto-populating folders.” Those folders do not play well with libraries or classes (by design, not because of a bug), and they make it hard to remove items from a project but keep the files around (because deleting from the folder is automatically deleting from disk). There are plenty of others who agree with me. But they are nice for simple apps that don’t use any modern software design tools.

QGraphicsItem does not show

I wrote a simple application that displays QGraphicsPixmapItems in a QGraphicsScene. The application should be portable without installing Qt on the operating system. I managed to copy only the needed dll files to start the application. Everything works except the QGraphicsItems are not displayed at all, although they are in the scene (wrote a logfile that counts the items).
I figured out that the items are shown correctly, if I copy my "portable" exe file into Qt\Qt5.2.1\5.2.1\mingw48_32\bin folder.
The opposite does not work: If I copy all of the bin-folder to my portable application folder, it does not work. How can I use a QGraphicsItem in a portable Qt application?
you might miss a plugin for the images you want to display.
make sure your application directory looks like this:
<root>
- <executable>
- <imageformats>
- <used image libraries>
I found the reason: I needed to add the folder Qt\Qt5.2.1\5.2.1\mingw48_32\plugins\imageformats to my "portable-app"-folder. In particular, the needed dll was qjpeg.dll.

installing a qt widget for qt designer

I downloaded a very useful widget for my applications. A LED indicator from http://qt-apps.org/content/show.php/QLedIndicator?content=118610
But there is no README file or any instruction files.
I unzip it and gave qmake QLedIndicator.pro and then make it compiled well without errors.
But I have no idea how to add the widget in Qt Designer, so I can drag and drop it where I need.
I'm using qt 4.8.3 with mingw. qt creator 2.6.0
Under Linux you just need to copy the file libQLedIndicatorPlugin.so in the
/usr/lib/qt/plugins/designer/
directory (or whatever is the directory on your distro).
Under Windows the process is similar, but you need to pay attention to the building process, as explained on the bottom of the page I linked
Qt's plugin architecture allows you to add custom widget to the designer. You can check out this official qt's link to do so - http://doc.qt.digia.com/4.7/designer-customwidgetplugin.html

Refresh flex spark theme

I have two flex projects: A project with my custom theme and another project in which I want to use my custom theme. However, every time I modify the theme, I have to import it again, clean and refresh the project. I am using Flash Builder 4.5. Does anybody know a better way to use the custom themes?
I found the solution to the problem. It is not that difficult and the results are great; you will be able to edit the theme, go to the design view of the project using the theme and see the results (no imports, no cleans, no refreshes).
Steps:
Open both projects at the same time in Flash Builder
In the main project (the project using the theme), go to Project > Properties > Flex Build Path
Select the Library Path tab and click Add Project
Select the project containing the theme
You're done! The main project will now depend on the theme and will recompile the theme every time you build.
Hope it helps!

Compiled distribution of Qt application for windows

I was successfully able to compile and run my Qt application. However, when I move the .exe file outside its original path, I found out that I have to manually copy the Qt DLLs (e.g. mingw10.dll, qtcore4.dll). Is there any dynamic way to link these libraries with my application?
I think you mean you want to "statically" link these libraries with your application.
Basically this means that everything will be rolled inside your exe, and you will have no need of those dlls anymore.
There are advantages to to static linking, but there are also disadvantages as well. You should be absolutely sure that this is what you want to do before you go this way.
Check out this link which explains the difference in depth Dynamic Linking vs Static Linking
As for your specific issue, if you are sure you want to use static linking you will have to change your Qt setup to be built statically. By default the Qt distribution is setup to use dynamic linking. There is a handy guide for that here.
Basically when you setup the build you have to run "configure -static" to change all the project settings to use static linking instead of dynamic linking. And then build Qt over again.
You should also verify your Qt license. If you are using the Qt LGPL license and you want to to link statically you will have to include all your object files (.o and .obj) as Mihai Limbășan wisely explained in his comment. If you have bought and paid for Qt, then you have no problem.
If the DLLs are on the PATH for the application, then they will be found and work. So, you could add where your Qt binaries/dlls are into the %PATH% environment variable. If you're going to create an installer for your application, you'll need to either package these libraries in so they're in the bin directory - or you'll have to expect every user to install and possibly compile Qt themselves (hint: go with the first option. :) )

Resources