Displaying Arabic Font error in windows
I have 64-bit Windows 11 and I tried the method in the link
https://support.cranksoftware.com/hc/en-us/articles/360057423571-Displaying-Arabic-Font
...but when running it shows errors
ERROR [0.025783]:Problem loading Lua script [utf8.lua] ..._y/storyboard_workspace/Translation/scripts/utf8.lua:6: module 'bit' not found:
no field package.preload['bit']
no file 'C:/Users/moh_y/storyboard_workspace/Translation/scripts/bit.lua'
no file 'C:/Program Files/Crank_Software/Storyboard_Designer/plugins/com.crank.gdt.simulator.runtime.win32_8.1.0.202402081836/resources/lua/64bit/lua\bit.lua'
no file '.\bit.lua'
no file 'C:\Program Files\Crank_Software\Storyboard_Engine\8.1-stable.202402081352\windows-x86_64-opengles_2.0-obj\bin\lua\bit.lua'
no file 'C:\Program Files\Crank_Software\Storyboard_Engine\8.1-stable.202402081352\windows-x86_64-opengles_2.0-obj\bin\lua\bit\init.lua'
no file 'C:\Program Files\Crank_Software\Storyboard_Engine\8.1-stable.202402081352\windows-x86_64-opengles_2.0-obj\bin\bit.lua'
no file 'C:\Program Files\Crank_Software\Storyboard_Engine\8.1-stable.202402081352\windows-x86_64-opengles_2.0-obj\bin\bit\init.lua'
no file 'C:/Users/moh_y/storyboard_workspace/Translation/scripts/windows-x86_64/bit.so'
no file 'C:/Program Files/Crank_Software/Storyboard_Designer/plugins/com.crank.gdt.simulator.runtime.win32_8.1.0.202402081836/resources/lua/64bit\bit.dll'
no file '.\bit.dll'
no file 'C:\Program Files\Crank_Software\Storyboard_Engine\8.1-stable.202402081352\windows-x86_64-opengles_2.0-obj\bin\bit.dll'
no file 'C:\Program Files\Crank_Software\Storyboard_Engine\8.1-stable.202402081352\windows-x86_64-opengles_2.0-obj\bin\loadall.dll'
Failed to run engine using file: C:/Users/moh_y/storyboard_workspace/Translation/sbsim-0.tmp
What is the solution to solve this problem? How do I create a bit file on Windows?
Comments
Hi Salem,
I have taken a look to the demo this morning and I was able to reproduce the issue, and also to have the app running. There are a couple of things to fix there.
1. The error suggests that there is a pathing mismatch. Let fix that first. on the utf8.lua I used an "absolute" path as hot fix, you may want to take a look to see how to properly point to those libs in your project. note: be sure to point to the .dll and not to .so since you are using windows. I replaced:
for:
2. Once 1 is fixed you would run into the next issue. The bit lib seems to be not compatible with the 64bit architecture. To work that around replace:
for:
Alternately you should look for another library 64bit compatible.
3.After solving 1 and 2 you should be able to run the app but will notice that the translation is not working. (you should see only "11111" instead of Arabic glyphs). There is a bug on the lenguage.lua script. To fix that you need to change line 44. replace:
for:
And that should fix all the issues.
let me know how it goes.
br,
Max
Firstly, thanks Max for the quick response
The application actually worked, but when I type Arabic text in the text field, it appears in the program as justified, but when I run it, each letter appears separately, not exactly, and in reverse.
Hi Salem,
Great to hear the app worked.
To connect the glyphs in HLOS we use a plugin called Harfbuzz.
If they appear separately the plugin may be missing or deactivated.
Please check the plugins directory on your engine folder to ensure that it is present, and also ensure that is activated in the simulator configurator windows.
Example of this demo with Harfbuzz:
Example of this demo without Harfbuzz, (deactivating the plugin from the simulator configuration window):
If understand correctly, by "not exactly" you mean that the translation is not proper? I cannot comment on the part because I do not speak the language. finally, regarding the reverse part, If I recall correctly the right-to-left switch is made in Lua, you can take a look to the script. But again, unfortunately I cannot comment on the accuracy of the translation.
I hope this helps.
br,
Max
This remains the problem... which is that the Arabic text appears intact in the application, but when simulate , it appears reversed
Hi Salem,
this behavior is expected.
when you first start this conversation, you mentioned a link to an article. if you go there and scroll to the bottom, you will see a link to a video which explains why this happens and how to easily work it around in lua.
hope this helps,
br,
Max
Thank you for following up. The problem has already been resolved
Hi Salem,
excellent, happy to help.
br,
Max
How do I solve this problem, knowing that I use the id and not a variable?
But when exported, it will be like this
Hi Salem,
can you please give us more details of what are you doing?
what I can tell you already is that most likely the harfbuzz plugin is failing to be linked since the glyphs are not connected and I am not sure about the interrogation marks, but it may be caused by some errors on your script or used libraries.
Max
I uploaded the entire project.. I hope to know where the problem is.. The library was added but it did not work
https://www.mediafire.com/file/rcx1icpnd2ujbqh/ZZ.rar/file
Hi Salem,
please create a support ticket, and we will provide a link to upload your project in our secure platform
br,
Max
Please sign in to leave a comment.