App icons?


#1

Hi all,

Since i’m getting close to first public demo’s of my new upcoming juce powered app,
i’m adding my executable icons.

this is the kind of stuff that i normally never do so i’m an idiot when it comes to these things :wink:

is there any functionality in juce to add them ?

i’ve went through the documentation and had a look at documentwindow and JUCEApplication classes but there aren’t any methods related to them.
i can add them to my resources in vs studio but i seem to only get my main icon to work (the 32x32), not the 16x16 for window manager and small icon overviews.

would be cool if juce can handle this in a platform independent way, does it somehow ?

Radiance


#2

Sorry - there’s no platform-independent way to do this. On windows you just have to create an icon file that contains the different resolutions, I thought?


#3

it’s not juce that does that it’s each platform compiler.

on win you need to add a resource to the project (look at the JUCER build)
on XCode it’s a property of the target youre building it has a special ICON property (you need to use ICNS format)


#4

Linux has no such property icons for applications depend on the WIndow Manager, it’s all about Gnome/KDE themes (messed up)


#5

This might be a good feature to add to the new Jucer when it’s ready - because that’ll be generating all the projects, it could also create icons for each target platform.


#6

be my guest :slight_smile:

i’ll do it the way atom has suggested then, via the visual studio resource view.

btw, maybe a little off-topic here, but the juce website seems to be very slow from here since a few days.
i’m frequently getting response times of 4-5 seconds for pages to load. (mostly php pages like the forum)

Thanks again, and enjoy your new years parties tonight everyone :slight_smile:
Radiance


#7

[quote]btw, maybe a little off-topic here, but the juce website seems to be very slow from here since a few days.
i’m frequently getting response times of 4-5 seconds for pages to load. (mostly php pages like the forum)[/quote]

I haven’t noticed it being any slower than normal - maybe just your connection?


#8

There will be a way to specify a different output project to generate from the jucer ?
i’m actually using qt-creator and i can have a single project file for 3 different platform (linux-gcc, windows-mingw and macosx-gcc) so i would love to be able to add a function to the jucer to export this single project file instead of exporting a different project for each platform that i have to maintain (and qt-creator works so nicely with juce… a cross platform ide for a cross platform library!).

ps. here it is a simple qt-creator project file for a juce application:

TEMPLATE = app
TARGET = juce_qt_creator
CONFIG = debug_and_release x86 sse mmx exceptions rtti stl threads
QT =
DEFINES =
INCLUDEPATH = ../src

HEADERS += $$PWD/../src/juce_config.h \
           $$PWD/../src/juce_header.h

SOURCES += $$PWD/../src/juce_library.cpp \
           $$PWD/../src/main.cpp

unix {
    CONFIG += x11
    DEFINES += LINUX

    QMAKE_CXXFLAGS = -march=i686 -pipe
    QMAKE_CXXFLAGS_DEBUG = -O0 -gdwarf-2 -g3
    QMAKE_CXXFLAGS_RELEASE = -O3 -s -momit-leaf-frame-pointer -fvisibility=hidden -funroll-loops  -fno-fast-math

    QMAKE_LFLAGS = -Wldead_strip -Wlno_dead_strip_inits_and_terms -rdynamic \
        -L/usr/lib \
        -lasound \
        -lfreetype \
        -lX11 \
        -lrt \
        -ldl \
        -lpthread

    INCLUDEPATH += /usr/include/freetype2

    debug {
        DEFINES += DEBUG _DEBUG
        DESTDIR = ../bin/linux/debug/
        OBJECTS_DIR = ../bin/linux/debug/temp
    }
    release {
        DEFINES += NDEBUG
        DESTDIR = ../bin/linux/release/
        OBJECTS_DIR = ../bin/linux/release/temp
    }
}

win32 {
    CONFIG += windows
    DEFINES += _WIN32

    QMAKE_CXXFLAGS = -mwindows
    QMAKE_CXXFLAGS_DEBUG = -O0 -gdwarf-2 -g3
    QMAKE_CXXFLAGS_RELEASE = -O3 -s
    QMAKE_LFLAGS = -mwindows

    INCLUDEPATH += "C:\MinGW\include"

    LIBS += "C:\MinGW\lib\libmingw32.a" \
        "C:\MinGW\lib\libkernel32.a" \
        "C:\MinGW\lib\libuser32.a" \
        "C:\MinGW\lib\libgdi32.a" \
        "C:\MinGW\lib\libcomdlg32.a" \
        "C:\MinGW\lib\libshell32.a" \
        "C:\MinGW\lib\libole32.a" \
        "C:\MinGW\lib\libopengl32.a" \
        "C:\MinGW\lib\libws2_32.a" \
        "C:\MinGW\lib\libmsvfw32.a" \
        "C:\MinGW\lib\libmsvcrt.a" \
        "C:\MinGW\lib\libdsound.a" \
        "C:\MinGW\lib\libwinmm.a" \
        "C:\MinGW\lib\libwininet.a" \
        "C:\MinGW\lib\libversion.a" \
        "C:\MinGW\lib\libuuid.a" \
        $$PWD/resource_icon.res

    debug {
        DEFINES += DEBUG _DEBUG
        DESTDIR = ../bin/win32/debug/
        OBJECTS_DIR = ../bin/win32/debug/temp
    }
    release {
        DEFINES += NDEBUG
        DESTDIR = ../bin/win32/release/
        OBJECTS_DIR = ../bin/win32/release/temp
    }
}

and with this you can compile straight away with linux and windows on the same ide !

(the macosx version i’m still refining but will be there in a short while)


#9

Hi Kraken,
Did you use the make file to compile juce on Linux or you used qt-creator for it.


#10

[quote]There will be a way to specify a different output project to generate from the jucer ?
i’m actually using qt-creator and i can have a single project file for 3 different platform (linux-gcc, windows-mingw and macosx-gcc) so i would love to be able to add a function to the jucer to export this single project file instead of exporting a different project for each platform that i have to maintain (and qt-creator works so nicely with juce… a cross platform ide for a cross platform library!).[/quote]

That’s precisely what I’m working on right now. The jucer will let you edit your project tree, build settings, etc. and will spit out XCode, VC or makefile projects. My original plan was to use something like CMake to generate these, but that didn’t quite do what I needed, so am rolling my own (which is actually not too hard).


#11

Actually i’m using the amalgamated version of juce, so i don’t need to stick with compiling my own library. Anyway i have plans in making a qt-creator project file for juce as this seems so in a good shape now to be used productively.

@ Jules:
i understand your point. the problem with this is that you are forcing by using a VC on windows for example (while i’m using gcc-mingw and qt-creator). i would appreciate a lot and give kudos if it will be easy to plug in class to write an own output project file from the JucerV2…


#12

Oh yes, none of the formats will be hard-wired. I’m doing those formats first because that’s what most people use, but adding new ones will be easy.


#13