How can I use CSS styling in my GTK# application? - css

How can I use CSS styling in my GTK# application? I heard before that it is impossible to use CSS themes in GTK#, but after that I found this example of using css styling in GTK#. Besides this I found also the samples of using CSS styling in Banshee project (which uses GTK#). So how is it possible? I already tried to do the same in GTK#, but I didn't find CssProvider class.
So how I can find this class in GTK# or how I can using CSS styling in GTK#?

CSS Styling is a GTK3 feature.
GTK# for GTK3 is not released as stable yet.
Xamarin (the main force behind mono) have publicly announced that their product (Xamarin Studio/Mono Develop) will not be moving to GTK3. This means that GTK3 support must come from the community and as a result has been very slow in coming.
It is likely that you cannot find the CssProvider class because you are using the GTK2 bindings not the GTK3 bindings.
If you would like to try the beta GTK3 csharp bindings then you can find them here:
https://github.com/mono/gtk-sharp/releases
Because Xamarin Studio will not work with GTK3 I would recommend either:
Compiling GTK# yourself such that Xamarin Studio can continue to run on the installed GTK2 bindings.
Use Visual Studio which has no dependency on GTK#

Related

Tailwind CSS 3.0 Disable JIT Mode

I Understand that the Tailwind CSS uses a new JIT engine by default from version 3 onwards.
AS JIT generates the CSS classes on demand, the text editors/IDE fails to show CSS class suggestions via IntelliSense.
Also, it will be an added advantage for developers during the development process without purging the CSS every time. As Tailwind CDN doesn't support third-party tailwind plugins (E.g tailwind-scrollbar) developers cannot rely on it.
Is there a way to disable the JIT mode
Is there any workaround to overcome the IntelliSense issue?
You can see more at this topic on Github here:
https://github.com/tailwindlabs/tailwindcss/discussions/6347

Eclipse: why is CSS syntax highlighting not working consistently?

I have a puzzling situation. Using Eclipse Oxygen.
One project, which I think I started as a Web Project in Eclipse Neon, does syntax highlighting for CSS files.
My new project, which I think started out as a PyDev Project here in Eclipse Oxygen, does not do highlighting for CSS files.
I'm unclear about the types of project because neither of the icons in Package Explorer (which are different) seems to correspond to any of the possible projects when you go File --> New (I've looked at all of them, including the icons under Other).
So it's really 2 questions: how do I find out what project type I'm working on... and how then do I configure the PyDev one (if such it be) to apply syntax highlighting to CSS.
Incidentally, the PyDev project is using a project location outside the default Workspace, not that this should make any difference.
Installation instructions can be found in the WTP Wiki at https://wiki.eclipse.org/WTP_FAQ#How_do_I_install_WTP.3F . Or you can use the Marketplace entry for it at https://marketplace.eclipse.org/content/eclipse-web-developer-tools-0 .
As suggested earlier, I believe you were missing highlighting because the WTP tools weren't installed in your PyDev environment. Nevertheless, if you need to spend more than a few minutes working with CSS, I would encourage you to give CodeMix a try for truly superlative CSS support in Eclipse:
Supports all the CSS 3 properties, including support for variables
In-built Emmet integration reduces typing required
Includes a CSS validator
Sass and LESS supported too
For more, see: https://www.genuitec.com/tech/css3-in-eclipse/

Is it possible to customize the style of javafx native package installer?

I have a javafx application which I package it with javafx-maven-plugin (windows installer).
I could also package it with ANT script.
My question is, I could change the Icon of the installer. But is it possible to change the install wizard style? like button colors, caption, add a logo, background image, etc?
There are several 3rd party components which allows to change the design of Inno Setup installer.
The most well known and officially recommended (http://jrsoftware.org/is3rdparty.php) by Inno Setup are:
1) Graphical Installer (http://www.graphical-installer.com) - extension that allows to customize almost every aspect of installer (background, buttons, icons, fonts, colors, ...). Commercial plug-in (I was personally involved in development):
2) VCL Styles for Inno Setup (https://github.com/RRUZ/vcl-styles-plugins/wiki/Inno-Setup) - free and Open Source plugin (dll) that allows you to add skins to the Inno Setup installers.
3) ISSkin (http://isskin.codejock.com/) - free version of Codejock’s Skin Framework that allows add customized skins to installer.

Flex Library Project: NativeMenu vs. ContextMenu

I have a Flex Library Project which has both Flex specific classes, and Air specific classes.
When I reference the library in an Air project, the compiler complains about an overriding contextMenu in mx.containers.Panel, saying that the param should be of type NativeMenu (instead of ContextMenu). If I switch it over to NativeMenu then it compiles fine.
The issue is when I reference the library in a Flex Project. This time it complains that it doesn't know the type NativeMenu. If I try to change it back to ContextMenu, then I get the same error as above.
I've searched google to no avail (found that someone else encountered the exact same problem: http://forums.adobe.com/thread/598791?tstart=-1 )
The docs don't help too much either, except stating the above: http://livedocs.adobe.com/flex/3/langref/flash/display/InteractiveObject.html#contextMenu
I'm thinking that its just not possible to do the mixing of Flex vs Air SDKs that I want, but I was hoping that maybe someone has figured this out.
Thanks!
You can't really target the web Flash Player and the desktop Player using the same project.
I would recommend encapsulating out as much functionality as possible into a library project. Then create a single Flex project and a single AIR project, both using the same library project.
Each respective project can extend, or replace, the different functionality.
I am not sure if this is the exact same problem, but I was having an issue with being able to reference the AIR libraries in a Flex Library project and found the (rather simple) solution.
Using Flash Builder 4.5, when creating a Flex Library Project, (right-click .. New.. Flex Library Project) there is a checkbox for "Include Adobe Air Libraries" at the bottom. This must be checked or AIR libraries will not be included.
When you select the version of SDK/AIR you are using in the dropdown, the message should also indicate what the minimum version of AIR required is for your application.

Creating Flex 3.5 components with Flash CS5

Is there a way to create components compatible with Flex 3.5 by using Flash CS5? I'm stumped. Whenever I run the "Convert Symbol to Flex Component" command and then try to use the resulting .swc file in a Flex 3.5 app, I get multiple instances of the following error:
1046: Type was not found or was not a
compile-time constant: Matrix3D.
1046: Type was not found or was not a
compile-time constant: Vector3D.
Any help or suggestions?
I had the same problem. I found a work around, though. You need to create the component using Flash Builder by dragging a Flash Professional Component onto your application. (You must be in Design Mode to do this.) Then, in the properties sheet, there will be a button labeled "Create In Flash Professional..." Clicking this button will create a Flash Document with all the correct frameworks and sdks and launch Flash Professional.
The errors you are seeing are usually brought on by a version mismatch between the Flex SDK that the SWC was compiled against and the Flex SDK of your project.
When creating SWCs using the Flash Pro interface, I'm not sure if they can be used in Flex. Generally SWCs are not sharable between Flex and Flash. People either recompile the source code or generate a SWF and embed it or load it using a SWFLoader.
If you're using the Flex Component Kit for Flash make sure you're using the same kit that came with the SDK you plan to target.

Resources