# How to get text(); vertical

**URL:** <https://discourse.processing.org/t/how-to-get-text-vertical/24685>\
**Category:** Coding Questions\
**Created:** [October 18, 2020, 9:07pm UTC](https://discourse.processing.org/t/how-to-get-text-vertical/24685 "2020-10-18T21:07:08Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ellie98](https://avatars.discourse-cdn.com/v4/letter/e/e47774/32.png) [@Ellie98](https://discourse.processing.org/u/Ellie98)\
**Post date:** [October 18, 2020, 9:07pm UTC](https://discourse.processing.org/t/how-to-get-text-vertical/24685/1 "2020-10-18T21:07:08Z")

</div>

How do I get the numbers vertical? Starting from 0 down to 9

```auto
char alphabet = 'a';
char nextChar;
float chatX = 20;
int spacing;

char neuChar;
float chaX = 20;
char alp = 'Z';

char zahlenChar;
float chaXX = 5;
char count = '0';

void setup() {
  size(420, 330); 
  spacing = width/30;
  surface.setTitle("Farbiges_Alphabet");
}

void draw() {
  background(0);
  textSize(24);
  float nextChatX = chatX;
  for ( int i = 0; i < 26; i++) {
    nextChar = char(alphabet + i);
    textSize(24);
    fill(random(255), random(255), random(255), random(255));
    noLoop();
    text( nextChar, (nextChatX) + (spacing * i), 25);

    float neuCharX = chaX;     
    int r = -1;
    while (r < 25) {
      r++;
      neuChar = char(alp - r);
      textSize(24);
      fill(random(255), random(255), random(255), random(255));
      noLoop();
      text( neuChar, (neuCharX) + (spacing * r), 310);
      
      float zahlenCharX = chaXX; // **here are the numbers**
int s = -1;
do {
  s++;
  zahlenChar = char(count + s);
  textSize(24);
  fill(random(255), random(255), random(255), random(255));
  noLoop();
  text( zahlenChar, (zahlenCharX) + (spacing+30*s),100);
} while (s < 9);
    }
  }
}

```

---

<div class="post-metadata">

**Author:** ![glv](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/glv/32/18785_2.png) [@glv](https://discourse.processing.org/u/glv)\
**Post date:** [October 18, 2020, 9:20pm UTC](https://discourse.processing.org/t/how-to-get-text-vertical/24685/2 "2020-10-18T21:20:08Z")

</div>

Hello,

For starters…

Try working with swapping the x, y for text() output.  
Then you will have to clean it up a bit for the spacing.

_[https://processing.org/reference/text\_.html](https://processing.org/reference/text_.html)_

`:)`

---

<div class="post-metadata">

**Author:** ![Ellie98](https://avatars.discourse-cdn.com/v4/letter/e/e47774/32.png) [@Ellie98](https://discourse.processing.org/u/Ellie98)\
**Post date:** [October 18, 2020, 9:21pm UTC](https://discourse.processing.org/t/how-to-get-text-vertical/24685/3 "2020-10-18T21:21:17Z")

</div>

I will try it out, thanks!
