Announcement

Collapse
No announcement yet.

Display charaters like, Copyright sign

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

  • Display charaters like, Copyright sign

    How can i display charaters like the Copyright sign in DOS or a windows DOS box?

    Is there a way to remap the keyboard keys?

    Thanks
    Jason

    ------------------

  • #2
    The (C) symbol is not available in the standard ASCII character table, so in full screen DOS mode, it is not possible to display this character unless the video card's character table is remapped - PB/Vision utilizes this method to emulate a GUI interface. Alternatively, you could use a graphics mode and draw the character on the screen.

    However, when a DOS window is windowed (non-fullscreen) then windows provides an "emulated" display of the DOS screen, where the font being used to display the DOS box can vary (and be changed by the user), and the actual visible results in terms of window size and displayed character set will depend on the font that is used.

    In this case, any characters that appear remapped in full-screen will no longer appear to be remapped in a windowed DOS box. This is why PB/Vision GUI interfaces must run in full-screen mode.

    So, not only can Windows use one of a (fairly limited) range of fonts to provide the emulated display of the text screen, some fonts may or may not include the (C) character. ALso, when the app is switched back to full-screen, the appearance will change back.

    The range of fonts that Windows includes for DOS box support is limited, but some 3rd-party fonts ($) can be obtained. If your need for such a font is great then purchasing a font may be the best solution, unless you want to run full screen, in which remapping a character or two may be the best solution for you.

    Remapping the keyboard keys is usually done by a keyboard driver, such as KEYB.SYS (in CONFIG.SYS) and loaded during boot-up.

    Everything is simple today...not.

    ------------------
    Lance
    PowerBASIC Support
    mailto:[email protected][email protected]</A>
    Lance
    mailto:[email protected]

    Comment


    • #3
      Do you have any examples on how to remap to those keys.

      (C) for instantance

      Jason

      ------------------

      Comment


      • #4
        I'm thinking there is some confusion here between keys and fonts. Keys
        are what you press on a keyboard. Fonts are what you see on the screen.
        There is no direct relationship between the two. It sounds like what
        you want is not to remap the keys, but to remap the fonts, which is an
        entirely different matter.

        Lance's reply covered the issues involved with font twiddling quite
        nicely. You may wish to read his message again.

        I believe there are some examples of DOS font remapping in the Downloads
        area here, if that seems like a good bet to you.

        The use of "(C)" in place of the copyright symbol is fully traditional
        in DOS programs and shouldn't cause you problems. Generally speaking,
        the word "Copyright" itself is sufficient, anyway. Finally, if you need
        a single-character "(C)" and can't find a better solution, you might
        consider substituting the at sign: "@".

        ------------------
        Tom Hanlin
        PowerBASIC Staff

        Comment


        • #5
          Hi folks,

          On my machine CHR$(169) really works.

          ------------------
          mailto:[email protected][email protected]</A>
          www.basicguru.com/zijlema/

          Egbert Zijlema, journalist and programmer (zijlema at basicguru dot eu)
          http://zijlema.basicguru.eu
          *** Opinions expressed here are not necessarily untrue ***

          Comment


          • #6
            [/b]Tom Hanlin[/b] wrote:
            The use of "(C)" in place of the copyright symbol is fully traditional in DOS programs and shouldn't cause you problems. Generally speaking, the word "Copyright" itself is sufficient, anyway. Finally, if you need a single-character "(C)" and can't find a better solution, you might consider substituting the at sign: "@".

            Just as an aside - while (C) may suffice for display purposes, the last time I checked it is not recognized as a "legal" copyright symbol for purposes of establishing copyright date and authorship. For that, you either have to have the C-in-a-circle symbol, or the word "Copyright" in your copyright notice.

            ------------------

            Comment


            • #7
              On my Win95 PC, just starting PB/DOS 3.5 and compiling the line

              Code:
              CLS:FOR V = 22 TO 254: PRINT V; CHR$(V);"  ";:NEXT
              produces a table of chars where at position 169 there is the registered-trademark symbol (R inside a circle), and at position 184 there is the Copyright symbol (C inside a circle).
              This works in pure DOS, in a windowed DOS box and in a full-screen DOS box.

              If you can’ t get CHR$(184) to work, probably you have specific DOS fonts settings or similar on your PC. On my PC, with no intended DOS fonts settings nor particular PB/DOS settings, it works.


              ------------------

              Comment


              • #8
                I'll lay odds that you are not using a US code page or locale, right?



                ------------------
                Lance
                PowerBASIC Support
                mailto:[email protected][email protected]</A>
                Lance
                mailto:[email protected]

                Comment


                • #9
                  I guess, you're right, Lance!
                  Davide is an Italian, I'm a Dutchie. That explains why CHR$(169) is the Copyright character on my machine, while on Davide's PC it displays the Trademark.
                  In conclusion: when Jason wants to write international software, it is wise to use "(C)" instead.

                  ------------------
                  mailto:[email protected][email protected]</A>
                  www.basicguru.com/zijlema/

                  Egbert Zijlema, journalist and programmer (zijlema at basicguru dot eu)
                  http://zijlema.basicguru.eu
                  *** Opinions expressed here are not necessarily untrue ***

                  Comment


                  • #10
                    Thanks alot for your input.

                    The main problem that I have is the software were developing will be used
                    in the US and also in Europe. The correct code pages will be loaded there so
                    they will view the chars correctly, but when the data is view in the US there will be a problem.

                    ..So does any one have an idea on solving this???


                    Thanks
                    Jason

                    ------------------

                    Comment


                    • #11
                      May I suggest you review this thread again - the answers have been given to you already.


                      ------------------
                      Lance
                      PowerBASIC Support
                      mailto:[email protected][email protected]</A>
                      Lance
                      mailto:[email protected]

                      Comment


                      • #12
                        I know there must be a solution, within this threed, I just havent seen a solution yet.

                        I can try loading other code pages, but I dont know how that would work on US keyboards.

                        I need chars from code page 805 not just the (c), is loading another code page the only solution and
                        can I change the code page on the fly?


                        I'll keep pecking away at it, thanks for your help.


                        Jason


                        ------------------

                        Comment

                        Working...
                        X