I have some buttonSelect controls added to a toolbar like this:
ruleButtonBar2.addButtonSelect('addCondition', 3, "Add Condition", '', null, null, null, true);
If the “text” that is added to the button is “wide”, it is truncated by the browser (see screen shot).
How can I control positioning such that text is on screen?
Darya
#2
Hello
If you use the PRO Edition and you have active support subscribtion, please create a ticket in the online support system.
Andrei
#3
hi
dhtmlxtoolbar.js, line ~1870:
if (that.rlt) {
...
} else {
self.polygon.style.left = getAbsoluteLeft(self.obj)+that.selectPolygonOffsetLeft+"px";
}
change to:
if (that.rlt) {
...
} else {
var x1 = document.body.scrollLeft;
var x2 = x1+(window.innerWidth||document.body.clientWidth);
var newLeft = getAbsoluteLeft(self.obj)+that.selectPolygonOffsetLeft;
if (newLeft+self.polygon.offsetWidth > x2) newLeft = getAbsoluteLeft(self.arw)+self.arw.offsetWidth-self.polygon.offsetWidth;
self.polygon.style.left = newLeft+"px";
}
We do have a licensed PRO edition… but thank you your suggested patch works great.