mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-03 10:22:45 -04:00
showbase: Parent the OSD to a2dTopLeft
The Y position is set to -0.1 as the original value was 0.9, so it was intended to be about 1 unit down from the top. Closes #977
This commit is contained in:
parent
6c8066bb61
commit
16f489ac5b
@ -38,9 +38,9 @@ class OnScreenDebug:
|
|||||||
print("failed to load OnScreenDebug font %s" % fontPath)
|
print("failed to load OnScreenDebug font %s" % fontPath)
|
||||||
font = TextNode.getDefaultFont()
|
font = TextNode.getDefaultFont()
|
||||||
self.onScreenText = OnscreenText.OnscreenText(
|
self.onScreenText = OnscreenText.OnscreenText(
|
||||||
pos = (-1.0, 0.9), fg=fgColor, bg=bgColor,
|
parent = base.a2dTopLeft, pos = (0.0, -0.1),
|
||||||
scale = (fontScale, fontScale, 0.0), align = TextNode.ALeft,
|
fg=fgColor, bg=bgColor, scale = (fontScale, fontScale, 0.0),
|
||||||
mayChange = 1, font = font)
|
align = TextNode.ALeft, mayChange = 1, font = font)
|
||||||
# Make sure readout is never lit or drawn in wireframe
|
# Make sure readout is never lit or drawn in wireframe
|
||||||
DirectUtil.useDirectRenderStyle(self.onScreenText)
|
DirectUtil.useDirectRenderStyle(self.onScreenText)
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user