2013-08-24 1 views

답변

2

새로운 버전, Roassal2에서

| view | 
view := ROView new. 
-15 to: 10 do: [ :i | 
    view add: ((ROLabel verticalText interlineSpace: i) elementOn: 'hello world'). 
]. 
ROHorizontalLineLayout on: view elements. 
view open 

는 지원 레이블을 회전 않습니다. 위의 예제의 경우 , 지금 당신은 할 수 있습니다 :

| view | 
view := RTView new. 
-15 to: 10 do: [ :i | 
    view add: ((RTRotatedLabel new angleInDegree: -90) elementOn: 'hello world'). 
]. 
RTHorizontalLineLayout on: view elements. 
view open 

당신은 얻을 것이다 :

enter image description here

또 다른 예 :

| v shape | 
v := RTView new. 
shape := RTRotatedLabel new. 
shape angleInDegree: [ :cls | cls numberOfMethods negated/1.5 ]. 
shape text: [ :cls | ' ', cls name ]. 
shape color: (Color black alpha: 0.2). 
v addAll: (shape elementsOn: Collection withAllSubclasses). 

v canvas color: Color white. 
v open 

당신은해야합니다 :

enter image description here

도움이 되었기를 바랍니다. :

+0

차가운. 고맙습니다. 이미지를 추가했습니다. – MartinW

2

현재 Roassal는 이러한 기능을 지원하지 않습니다. 그러나 가까이에 뭔가를 얻을 수 있습니다. Roassal 1.422

+0

감사합니다. 그건 아주 흥미로운 해결 방법 :) – MartinW

관련 문제