enamo wrote:It is a interesting sharing......
What is?
| Friends: Coding 'n Cracking - Nymphaea - PS3 Forum - darkforestgroup - daxhordes.org - Tgames - coldbird - gopsp.it - pspstation.org - prometheus - hgoel.info - MakeSmartTV - ps vita |
enamo wrote:It is a interesting sharing......
Killerfeeshy wrote:Am I right in saying that if you have already loaded a font you can replace it with another one of the same name, for example
Font1 has been previously loaded
Now you load a new font but again call it Font1
Does this overwrite the first Font1?
Thanks
Zasisem wrote:Killerfeeshy wrote:Am I right in saying that if you have already loaded a font you can replace it with another one of the same name, for example
Font1 has been previously loaded
Now you load a new font but again call it Font1
Does this overwrite the first Font1?
Thanks
There's 2 ways someone can answer your question.
Answer 1
font_1 = Font.load("verdana.ttf")
font_2 = Font.load("verdana.ttf")
Notice we use the same font verdana.ttf but with different variable names. This is fine.
Answer 2
font_1 = Font.load("verdana.ttf")
font_1 = Font.load("spacefont.ttf")
The last font that was loaded spacefont will work as the variable font_1
So your answer is yes.. It will replace it
10$man wrote:I think that both fonts are still loaded, but you can't access the first of the two.
10$man wrote:I have loaded a massive amount of images into Luaplayer and had no problem with memory, so don't kill yourself over this.
cmbeke wrote:The easiest way to check if it overwrites or replaces would be to use System.getFreeMemory(), then load and unload a font a couple times to see if it works.
Users browsing this forum: No registered users and 2 guests