Show messages: All
1
2-7
From: Michael Gibson
Hi dune1982, when MOI starts up, just before it is ready to display the main window it will look in the appdata startup folder for any .js files and run each of those scripts.
It doesn't do anything for .htm files.
But it is possible for the .js script to modify the UI and insert things like buttons in the bottom command bar.
I'll make an example.
- Michael
From: Michael Gibson
Hi dune1982, here is an example - put StartupExample.js and TestIcon.png both inside the appdata startup folder. The script inserts a button into the bottom command bar.
- Michael
Attachments:
StartupExample.js
Image Attachments:
TestIcon.png
From: dune1982
Thank you Michael,
that did help and made it clear.
Is there a way now to make MoI not chache the files on startup. Currently I have to restart MoI on every change in a file.
I know there was a section in the moi.ini but i was not able to find it in V5
Also I have now moved everything in to my own folder in C:\Users\<user>\AppData\Roaming\Moi\plugins\<myplugin> where should i put my EnglishStrings.txt file so MoI can find it?
From: Michael Gibson
Hi dune1982,
re:
> Is there a way now to make MoI not chache the files on startup. Currently I have to restart
> MoI on every change in a file. I know there was a section in the moi.ini but i was not able
> to find it in V5
On
http://moi3d.com/wiki/Scripting look for:
"See here for info on disabling file caching so commands will reload on every run"
re:
> \Users\<user>\AppData\Roaming\Moi\plugins\<myplugin> where should i put
> my EnglishStrings.txt file so MoI can find it?
Currently MoI will only load string tables from the install's UI folder so there isn't a way to deploy your own string table in a plugin.
So in your .htm files don't use <moi:Text textid=""/> which looks up text in the string table, instead just put in your text directly.
So like this:
<moi:CommandButton>
Text</moi:CommandButton>
Instead of this:
<moi:CommandButton>
<moi:Text textid=""/></moi:CommandButton>
- Michael
From: dune1982
Ok so to make it multilingual, i have to come up with my own solution or put my strings in the original txt files.
See attached the section of my moi.ini, there is no DisableFileCaching
Image Attachments:
DisableFileCaching.PNG
From: Michael Gibson
Hi dune1982,
re:
> See attached the section of my moi.ini, there is no DisableFileCaching
You need to add in that line.
- Michael
Show messages: All
1
2-7