Coder Social home page Coder Social logo

zoelabbb / conio.h Goto Github PK

View Code? Open in Web Editor NEW
117.0 3.0 61.0 185 KB

This is a library conio.h for linux ๐Ÿ–ฅ๏ธ. you can install manual library conio.h for linux step by step here.

Home Page: https://zoelabbb.github.io/conio.h/

License: MIT License

C++ 96.07% Makefile 3.93%
cpp cpp-library cpp-lib library conio install linux library-conio administrator terminal

conio.h's Introduction

Library <conio.h> For Linux

What is #include <conio.h> ?

In C/C++ code, you often see the line #include <conio.h>. This line is used to include the <conio.h> file in your main program. The <conio.h> header file provides functions for input and output operations.

#include <conio.h> is a header file, conio stands for console-input-output and (.h) is basically header file extension.

It contains some functions and methods for formatting the output and getting input in the console.

The error will be shown like below :

conio h fatal error

If you encounter an error like conio.h: fatal error, this library might be what you need.

List of Functions in <conio.h>

The library provides various functions, including:

  • cprintf
  • cscanf
  • gotoxy
  • clrscr
  • textcolor
  • textbackground
  • wherex
  • wherey
  • getch
  • getche
  • ungetch
  • kbhit
  • putch
  • putchar
  • cputs
  • clreol
  • insline (not implemented)
  • delline (not implemented)
  • cgets (not implemented)
  • getpass (not implemented)
  • gettext (not implemented)
  • _cprintf
  • _cscanf
  • _cputs
  • _getche
  • _kbhit
  • _putch
  • _ungetch

Some commonly used functions:

  • kbhit - Checks if a key was pressed.
  • gcgets - Reads a string from the console.
  • cscanf - Reads formatted values from the console.
  • putch - Writes a character to the console.
  • cputs - Writes a string to the console.
  • cprintf - Formats values and writes them to the console.
  • clrscr - Clears the screen.
  • getch - Gets a character from the console.

How to Install the Library #include <conio.h>

Follow these steps to install the conio.h library for Linux:

Step 1:

  1. First, open your terminal as root.
    sudo apt-get update
    sudo apt-get upgrade
    sudo apt-get install git
    git clone https://github.com/zoelabbb/conio.h.git
    cd conio.h

    Copy & Paste

Step 2:

sudo make install

Restart or close your IDE and open it again.

Now you can use the library #include <conio.h>.

Support Me

If you find this library helpful, you can support the developer by:

Feel free to use and contribute to this library!

conio.h's People

Contributors

mazunki avatar zoelabbb avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

conio.h's Issues

Use in apache licensed project...

I want to use your conio implementation in my Apache 2.0 licensed game via GIT submodules; somewhere I read that this is fine, some docs say it would have to be MPL/MIT/BSD. Could you possibly clear this up for me?

Class error

after including in vs code for c. the error show unknown type name 'class'.
for better understanding i am sharing the screenshot. thank you..
Screenshot from 2022-11-08 10-19-04

Program crashes with "Illegal instruction" error

I'm using the conio.h library for a project of mine, and when I'm using the getch() function it stops with a highlight at line 239 of conio.h with a message "Exception has occured. Illegal instruction". I am using vscode with C++ extention pack and code runner.

Screenshot_20231214_173114

Screenshot_20231214_173241

Multiple definition when includeing conio.h in multiple cpp files.

Everything works fine when I include conio.h in a single file. But when I include it in two or more cpp files in the same project I get

/usr/include/conio.h:312: multiple definition of `___CONIO_H'; /tmp/ccvuHE5R.o:/usr/include/conio.h:312: first defined here

Of course the program builds just fine when conio.h is included in only one cpp file.

Style issues

Good afternoon.
Something strange is happening in this repository.
Oh my god, bring the code style to uniformity. Even your indents are not correct.
Why there are examples and installation instructions in .h, this is unacceptable!
Why README.md resembles a birthday cake, why do I need emoji, your contacts, I NEED A NORMAL DESCRIPTION.
Do the normal installation instructions, I NEED TERMINAL COMMANDS to install.
I'm surprised that this came up as my first search query.

But thanks. I found in this heap of information noise, the information I needed to write my own solution. It is impossible to use this in its current form.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.