如何在tcltk中旋转标签

时间:2018-08-13 15:27:32

标签: r tcltk

如何旋转以下tcltk ylabel?

library(tcltk)
library(tkrplot)

tt <- tktoplevel()
# pack xlabel and ylabel in tktoplevel instead of hist()
his <- tkrplot(tt, function() hist(rnorm(500), main = "hist", 
       xlab = NULL, 
       ylab = NULL))
tkgrid(his, row = 0, column = 1, rowspan = 5, columnspan = 5)
font <- tkfont.create(size = 16, weight = "bold")
xlab <- tklabel(parent = tt, text = "rnorm(100)")
tkconfigure(xlab, font = font)
tkgrid(xlab, row = 5, column = 1,
       rowspan = 1, columnspan = 5,
       sticky="nesw")
ylab <- tklabel(parent = tt, text = "Frequency")
tkconfigure(ylab, font = font)
tkgrid(ylab, row = 0, column = 0,
       rowspan = 5, columnspan = 1,
       sticky="nesw")

我检查了tkfont.create(),不允许angle。我想知道是否有什么方法可以在tcltk中旋转ylabel(而不在hist()中添加ylabel)?

0 个答案:

没有答案