Qt Gui Text to ASCII art



  • Hello guys , i am posting this after 2 weeks of hard search . I have no result for my project. So what i have to do is for every letter i introduce i have to output that letter drawn with ascii art. there is a site i will put in here so you can understand my problems. We had at school like 3 weeks to learn QT but i find it so hard to learn in 3 weeks. After some tutorials i managed to learn some base ,but i can't find what i need. So if anyone here who would like to help me i would be so happy. Here is the link to that site. I just need an text input, text output and a button . if you could do that thing for one letter i can do the others myself . i just need an example . Please help me . Thanks . http://patorjk.com/software/taag/#p=display&f=Graffiti&t=Type Something


  • Qt Champions 2018

    Hi @Losnariu12,

    can you at least solve parts of your problem yourself?

    Maybe start with a text input, a button and a text output. Then print the string from the text input in the text output when the button is pressed. Can you manage this part yourself?

    If that works, let's face the more complicated one. Somehow you need to convert a single character (like 'A') to a group of characters that form this 'A' in ASCII art. Spoken in programming language, each character in ASCII art is a two-dimensional array of chars. So you need a conversion table that transforms a single char into a 2D-array-of-chars. Do you think your programming skills allows to do this?

    Now comes the last one - it will be a bit tricky again. You now need to add these 2D-char-arrays to your output text - line by line. Means you will have to output the first line of all arrays described by your input text, followed by the second one and so on.

    Do you think that could work out? Then start coding. Start with the simple things. Try to convert one character to ASCII art first, see how it works before defining the whole alphabet.

    If you have specific questions, don't hesitate to ask here.



  • @aha_1980 Thanks for the answer . I will try your sugestions and see how it goes. I've done all this text to ASCII in console codeblocks C++ but it seems that i need a gui to it. I am not as good in Class'es and things like that. I will try it anyways. An example could be more than good for one letter . i could do the rest alone :P . Have a good night


 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.