יחידה:גרפים: הבדלים בין גרסאות בדף
ניסוי |
מ הוספת סיבוב כותרות למקרה שיש עומס |
||
| שורה 25: | שורה 25: | ||
radius = 'רדיוס', | radius = 'רדיוס', | ||
percent = 'אחוזים', | percent = 'אחוזים', | ||
xrotation = 'סיבוב כותרות', | |||
valueInBar = 'הצגת הערך בעמודה', | valueInBar = 'הצגת הערך בעמודה', | ||
| שורה 217: | שורה 218: | ||
local values, xlegends, colors, tooltips, yscales = {}, {}, {}, {} ,{}, {}, {} | local values, xlegends, colors, tooltips, yscales = {}, {}, {}, {} ,{}, {}, {} | ||
local groupNames, unitsSuffix, unitsPrefix, links = {}, {}, {}, {} | local groupNames, unitsSuffix, unitsPrefix, links = {}, {}, {}, {} | ||
local width, height, stack, delimiter = 500, 350, false, args[keywords.delimiter] or ':' | local width, height, stack, delimiter, xrotation = 500, 350, false, args[keywords.delimiter] or ':', 0 | ||
local chartWidth, chartHeight, defcolor, scalePerGroup | local chartWidth, chartHeight, defcolor, scalePerGroup | ||
local valueInBar = args[keywords.valueInBar] | local valueInBar = args[keywords.valueInBar] | ||
| שורה 289: | שורה 290: | ||
elseif k == keywords.scalePerGroup then scalePerGroup = true | elseif k == keywords.scalePerGroup then scalePerGroup = true | ||
elseif k == keywords.defcolor then defcolor = v | elseif k == keywords.defcolor then defcolor = v | ||
elseif k == keywords.xrotation then xrotation = v | |||
else | else | ||
for keyword, tab in pairs( { | for keyword, tab in pairs( { | ||
| שורה 421: | שורה 423: | ||
function drawXlegends() | function drawXlegends() | ||
local setOffset, setWidth | local setOffset, setWidth | ||
local legendDivStyleFormat = "position:absolute;left:%spx;top:10px;min-width:%spx;max-width:%spx;text-align:center;veritical-align:top;" | local rotationTransform = (tostring(xrotation)=='0' and '') or ('transform:rotate('..xrotation..'deg)') | ||
local legendDivStyleFormat = "position:absolute;left:%spx;top:10px;min-width:%spx;max-width:%spx;text-align:center;veritical-align:top;"..rotationTransform | |||
local tickDivstyleFormat = "position:absolute;left:%spx;height:10px;width:1px;border-left:1px solid black;" | local tickDivstyleFormat = "position:absolute;left:%spx;height:10px;width:1px;border-left:1px solid black;" | ||
for i = 1, numValues do | for i = 1, numValues do | ||