Hollywood and programs compiled with Hollywood recognize many console arguments that can be used to control various functions of the program. Most of the time, though, you won't start Hollywood or Hollywood-compiled programs from the console. So how can you pass these arguments to Hollywood programs when you don't have a console? This differs from platform to platform. Below is an overview of how to pass console arguments to Hollywood programs without using a console.
Note that by default, all programs compiled by Hollywood will handle console arguments and arguments passed to them using the mechanisms described below. If you would like to forbid this behaviour, you have to compile your programs using the -locksettings argument. Otherwise, the user will be able to change the appearance of your compiled program by passing arguments to it.
Here is how to specify console arguments to Hollywood programs without using the console:
Simply create an icon for your program and add the console arguments you
want to use as tooltypes to that icon. For example, to add a black-to-blue
gradient your program in
RAM:MyCoolProg, create an icon named
and add the following tooltypes to it:
BACKFILL=GRADIENT STARTCOLOR=$000000 ENDCOLOR=$0000ff BORDERLESS FIXED (FULLSCREEN)
Note that tooltypes enclosed in parentheses are ignored so in the above case,
FULLSCREEN is not handled.
Under Windows, you can put the console arguments you want to use in an
file accompanying your program. Let's assume you have compiled a program
MyCoolProg.exe with Hollywood. You have installed this program in
You can now create an
*.ini file which holds further options for this program.
*.ini file must have the same name as your program. Otherwise your
program will not be able to detect that there is an
*.ini file. Thus, you
have to create the
*.ini file as follows:
You can then use your favorite text editor to add options to this
file. For example, to create a black to blue gradient backfill for your
program, you can put the following tags in
Backfill=Gradient StartColor=$000000 EndColor=$0000ff Borderless=True Fixed=True
See console arguments for more information on which arguments can be specified in the *.ini file.
Under macOS, you can choose between two different ways of passing console arguments without using a console:
Info.plistinside the application bundle that was compiled by Hollywood with your favorite text editor. Now search for the dictionary entry named
CFBundleExecutableArgs. Here you can add all the console arguments you like now. For example:
<key>CFBundleExecutableArgs</key> <string> -backfill gradient -startcolor $000000 -endcolor $0000ff -borderless -fixed </string>
With these console arguments specified, your program will open with a black-to-blue gradient.
*.inifile just as you can do under Windows. See above for instructions on how to create such an
*.inifile. The only difference under macOS is that you have to put the
*.inifile inside the
Resourcesdirectory of your application bundle. For instance, if your app bundle is located in this path:
*.ini file has to go here then:
The rest is exactly the same as under Windows.
On Linux you can also put all console arguments in an
*.ini file. See above
for detailed instructions.