Commit c6dbfafe authored by Jonathan Wilkes's avatar Jonathan Wilkes
Browse files

fix placement of text inside nbx

parent 304f2be2
...@@ -1750,8 +1750,9 @@ function gui_create_numbox(width,cid,tag,bgcolor,p1,p2,p3,p4,p5,p6,p7,p8,p9,p10, ...@@ -1750,8 +1750,9 @@ function gui_create_numbox(width,cid,tag,bgcolor,p1,p2,p3,p4,p5,p6,p7,p8,p9,p10,
function gui_numbox_drawtext(cid,tag,text,font_size,color,xpos,ypos,basex,basey) { function gui_numbox_drawtext(cid,tag,text,font_size,color,xpos,ypos,basex,basey) {
var g = get_gobj(cid, tag), var g = get_gobj(cid, tag),
svg_text = create_item(cid, "text", { svg_text = create_item(cid, "text", {
x: xpos - basex, transform: "translate(" +
y: ypos - basey + 5, (xpos - basex) + "," +
(ypos - basey + 5) + ")",
"font-size": font_size, "font-size": font_size,
fill: color, fill: color,
id: tag + "text" id: tag + "text"
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment