[Gambas-user] [CRASH REPORT] Sdl Font Test
T Lee Davidson
t.lee.davidson at gmail.com
Sun Jan 13 07:50:43 CET 2019
I can get the sample SDL application to print the font name of a system font loaded in Main() with:
Font.Load("/usr/share/fonts/truetype/DejaVuSans.ttf")
by doing in Window_Draw():
Dim hFont As Font
hFont = Font["DejaVuSans"]
Print hFont.Name
But then if I try either of the following in that same Draw event:
Draw.Font = hFont , or
Draw.Font = Font["DejaVuSans"]
it SegFaults.
I sent a project a few days ago [0], but it might have gotten lost thanks to Gmail's 'super-intelligent' spam detection. Or, I
think more likely, Benoît is quietly working on it.
___
Lee
[0] https://lists.gambas-basic.org/pipermail/user/2019-January/066178.html
On 1/12/19 7:49 PM, Shane wrote:
> Hello,
>
> Damned, my program crashed Gambas that way :
>
> Public Sub Window_Draw()
>
> Dim H As Integer
>
> H = Font.DefaultHeight * 4
> Print Draw.Font.Name <-------- Seg Fault Here
> Draw.Clear
> Draw.Font.Size = H
> Draw.Text("Gambas", 0, 0)
> Draw.Text(CStr($hWindow.FrameCount), 0, H)
>
>
> ----[ Gambas mailing-list is hosted by https://www.hostsharing.net ]----
>
More information about the User
mailing list