Announcement

Collapse
No announcement yet.

OLD Fashioned chars

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    OLD Fashioned chars

    Hello dear PB experts.

    Today I'm trying to get old sweet boxes DOS like on a CONSOLE Win10, but it shows me something different than what I'd like to see.

    What SET / CONSOLE or other tweak to get (on console) old nice ASCII Characters and make a nice box?

    Actually it shows me OEM 850 as shown in the second image.

    Thanks
    Attached Files
    Last edited by salvatore renda; 20 May 2023, 09:46 AM.

    #2
    This is what I actually get
    Attached Files

    Comment


      #3
      see: List of Unicode characters - Wikipedia
      The box drawing characters are easy to find in the list at left of that page.

      In actual ASCII 0 to 31 are control characters, not the images used by DOS. Values 128 to 255 are not part of ASCII at all, which is a 7 bit code set. Those "upper" characters vary depending on if the set is Extended ASCII, OEM, ANSI, etc., etc. (that all use ASCII as the "lower" characters. {ref is MIL 188 for one, MS just abused the name. refs at ASCII - Wikipedia​ )

      I posted a Unicode tool around here somewhere. Be back when I find it

      Cheers,
      Dale

      Comment


        #4
        I don't see a second image, but a box commonly means "there is no glyph for that character in this font". Take a look at the Character Map applet.
        "Not my circus, not my monkeys."

        Comment


          #5
          Code:
          Found it:
          https://forum.powerbasic.com/forum/user-to-user-discussions/powerbasic-for-windows/822964-russian-dialog-caption?p=822973#post822973
          
          If linked ZIP on that page is still missing DLLs (specifically box drawing), then:
          https://forum.powerbasic.com/forum/user-to-user-discussions/powerbasic-for-windows/822964-russian-dialog-caption?p=822999#post822999
          
          also see:
          https://forum.powerbasic.com/forum/user-to-user-discussions/powerbasic-for-windows/822964-russian-dialog-caption?p=822999#post822999
          for a web tool found by Stuart in that thread​
          ((without the code tags text from those pages and a messed up image are shown here, but now the links are not "clickable"))
          -------------------------------------------------------------------------------------------------
          Eric triggered some other points.
          Use WSTRING for string variable.
          Some fonts in Character Map are only 8 bit.
          Some 16 bit fonts do not have glyphs for all "Western" characters and symbols ("Eastern" and right-to-left languages are a whole different story.)

          Cheers,
          Dale

          Comment


            #6
            CC6 Output compatible with CC5

            Code:
            #COMPILE EXE
            #DIM ALL
            
            #OPTION ANSIAPI        ' <------CC6 Output compatible with CC5
            
            FUNCTION PBMAIN () AS LONG
                LOCAL i&, t, t1 AS STRING
                FOR i = 1 TO 31
                    STDOUT CHR$(i,", ");
                NEXT
                PRINT  $CRLF
                STDOUT CHR$(176 TO 178,13,10)
                PRINT CHR$(192 TO 206)
                PRINT
                t = CHR$(201, 205, 203,205, 187)
                t1 = CHR$(200, 205, 202, 205, 188)
                PRINT t
                PRINT t1
             WAITKEY$
            
            END FUNCTION​
            CC6 Unicode Output
            Code:
            #COMPILE EXE
            #DIM ALL
            
            FUNCTION PBMAIN () AS LONG
            
                LOCAL i&, t, t1 AS WSTRING
                FOR i = 1 TO 31
                    PRINT OEMTOCHR$(GRAPHIC, CHR$(i, ", "));
                NEXT
                PRINT
                PRINT OEMTOCHR$(GRAPHIC, CHR$(176 TO 178))
                PRINT OEMTOCHR$(GRAPHIC, CHR$(192 TO 206))
            
                t = OEMTOCHR$(GRAPHIC, CHR$(201, 205, 203,205, 187))
                t1 = OEMTOCHR$(GRAPHIC, CHR$(200, 205, 202, 205, 188))
                PRINT t
                PRINT t1
            
                PRINT:PRINT
                'or
                t= CHR$$(9556, 9552, 9574, 9552, 9559)
                t1 = CHR$$(9562, 9552, 9577, 9552, 9565)
                PRINT t
                PRINT t1
            
            WAITKEY$
            
            END FUNCTION​

            Comment


              #7
              Originally posted by Horst Donath View Post
              CC6 Output compatible with CC5

              Code:
              #COMPILE EXE
              #DIM ALL
              
              #OPTION ANSIAPI ' <------CC6 Output compatible with CC5
              
              FUNCTION PBMAIN () AS LONG
              LOCAL i&, t, t1 AS STRING
              FOR i = 1 TO 31
              STDOUT CHR$(i,", ");
              NEXT
              PRINT $CRLF
              STDOUT CHR$(176 TO 178,13,10)
              PRINT CHR$(192 TO 206)
              PRINT
              t = CHR$(201, 205, 203,205, 187)
              t1 = CHR$(200, 205, 202, 205, 188)
              PRINT t
              PRINT t1
              WAITKEY$
              
              END FUNCTION​
              CC6 Unicode Output
              Code:
              #COMPILE EXE
              #DIM ALL
              
              FUNCTION PBMAIN () AS LONG
              
              LOCAL i&, t, t1 AS WSTRING
              FOR i = 1 TO 31
              PRINT OEMTOCHR$(GRAPHIC, CHR$(i, ", "));
              NEXT
              PRINT
              PRINT OEMTOCHR$(GRAPHIC, CHR$(176 TO 178))
              PRINT OEMTOCHR$(GRAPHIC, CHR$(192 TO 206))
              
              t = OEMTOCHR$(GRAPHIC, CHR$(201, 205, 203,205, 187))
              t1 = OEMTOCHR$(GRAPHIC, CHR$(200, 205, 202, 205, 188))
              PRINT t
              PRINT t1
              
              PRINT:PRINT
              'or
              t= CHR$$(9556, 9552, 9574, 9552, 9559)
              t1 = CHR$$(9562, 9552, 9577, 9552, 9565)
              PRINT t
              PRINT t1
              
              WAITKEY$
              
              END FUNCTION​
              thanks Horst, "#OPTION ANSIAPI" works as desired from ASCII code 32 onward.

              Attached Files

              Comment


                #8
                Originally posted by Eric Pearson View Post
                I don't see a second image, but a box commonly means "there is no glyph for that character in this font". Take a look at the Character Map applet.
                I posted it, but now I can't see it anymore


                Attached Files

                Comment


                  #9
                  Originally posted by Dale Yarker View Post
                  Code:
                  Found it:
                  https://forum.powerbasic.com/forum/user-to-user-discussions/powerbasic-for-windows/822964-russian-dialog-caption?p=822973#post822973
                  
                  If linked ZIP on that page is still missing DLLs (specifically box drawing), then:
                  https://forum.powerbasic.com/forum/user-to-user-discussions/powerbasic-for-windows/822964-russian-dialog-caption?p=822999#post822999
                  
                  also see:
                  https://forum.powerbasic.com/forum/user-to-user-discussions/powerbasic-for-windows/822964-russian-dialog-caption?p=822999#post822999
                  for a web tool found by Stuart in that thread​
                  ((without the code tags text from those pages and a messed up image are shown here, but now the links are not "clickable"))
                  -------------------------------------------------------------------------------------------------
                  Eric triggered some other points.
                  Use WSTRING for string variable.
                  Some fonts in Character Map are only 8 bit.
                  Some 16 bit fonts do not have glyphs for all "Western" characters and symbols ("Eastern" and right-to-left languages are a whole different story.)

                  Cheers,
                  Great bro! Thanks

                  Comment

                  Working...
                  X
                  😀
                  🥰
                  🤢
                  😎
                  😡
                  👍
                  👎