ATTN: linux - c / c++ ( writing console user interface ) need help

Discussion in 'OT Technology' started by durondude, Apr 27, 2005.

  1. durondude

    durondude OT Addict

    Joined:
    May 7, 2001
    Messages:
    24,063
    Likes Received:
    5
    Location:
    Earth, The Planet
    I'm writing a console program and I want a user interface similar to that of BitchX's (top portion of screen to display stuff, bottom portion to input commands and stuff). Could I do it in c++ or would I have to use only c or a mixture of both? Which libs would I need to use?

    To be more specific, I wrote a little chat client / server using c++ in windows.
    The server was console so it was easy to port over, but for the client, I used a dialogbox and the client under linux has to be console based and not xwindow.. I'm looking at the BitchX source and it looks like they're using the X11 libs also... if someone could point me towards the right direction, I'm sure I can figure out the rest... some links would be nice.
    :x:
     
  2. skinjob

    skinjob Active Member

    Joined:
    Jan 6, 2001
    Messages:
    2,337
    Likes Received:
    0
    Location:
    Aztlán
    I think you need something like the curses or ncurses library.
     
  3. durondude

    durondude OT Addict

    Joined:
    May 7, 2001
    Messages:
    24,063
    Likes Received:
    5
    Location:
    Earth, The Planet
    Thank you i will look more into this
     
  4. Penguin Man

    Penguin Man Protect Your Digital Liberties

    Joined:
    Apr 27, 2002
    Messages:
    21,696
    Likes Received:
    0
    Location:
    Edmonton, AB
    Yeah, I'd say that's probably the easiest and prettiest way to go.
     
  5. durondude

    durondude OT Addict

    Joined:
    May 7, 2001
    Messages:
    24,063
    Likes Received:
    5
    Location:
    Earth, The Planet
    I'm having trouble with the key press detection
     
  6. Joe_Cool

    Joe_Cool Never trust a woman or a government. Moderator

    Joined:
    Jun 30, 2003
    Messages:
    299,419
    Likes Received:
    594
    I'd love to help out, but I haven't learned curses yet. But from what I understand, that's THE way to do console programming.
     
  7. Penguin Man

    Penguin Man Protect Your Digital Liberties

    Joined:
    Apr 27, 2002
    Messages:
    21,696
    Likes Received:
    0
    Location:
    Edmonton, AB
    Yeah, I've never really played with curses either :embd:
     
  8. durondude

    durondude OT Addict

    Joined:
    May 7, 2001
    Messages:
    24,063
    Likes Received:
    5
    Location:
    Earth, The Planet
    well i figured it out... i didn't put in the correct window :rofl: it's cool I really like it now if I can do some multithreading with it.. it would be great heh
     

Share This Page