Why don't IDEs highlight string data type in C/C++? [closed] - c++

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 2 years ago.
Improve this question
I am using Sublime Text 3 and Atom to code C and C++. But they don't highlight string data type as shown below.
This issue is frustrating me when I use Atom and Sublime. This doesn't happen in Visual Studio Code.
Are there any ways to fix this issue except using Visual Studio Code instead?

For Atom:
Press Ctrl + ,(comma) to open Settings.
Go to Settings > Core.
Check Use Tree-sitter Parsers for supported languages.
Additional Steps:
Install Atom language support for C/C++ (Official) or C++14 language support (3rd Party).
For Sublime Text 3:
Install C++ Starting Kit or C Improved or C++11.
Note: The extensions/packages mentioned in this post are made by respective open source developers. I do not intend to promote a certain product.

Related

Running c or c++ code in standalone Xcode playground [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 2 years ago.
Improve this question
I would like to create a standalone playground and just drop a bunch of swift code into the Sources folder. I also have dependency on c/c++ code, so I also dropped those, and added a Bridging Header.
These bunch of files compiled together in an Xcode project. However, i can't get them to work as a standalone Playground. Note that I aint trying to write c in the playground, but Swift code that in terms are wrapper for that C.
Any idea how thats done? if possible.
Note: Not sure why my Q is voted down. It is legit. Again, I plan to write Swift code in playground, but need a 3rd party library that has C files in it.
Playgrounds are Swift only.
What I do when I'm experimenting with language subtleties is to use a Mac command-line tool. It doesn't have a UI, and doesn't have the overhead of launching the simulator. Command line tools can be in any combination of supported languages.
Obviously this wouldn't help if the code you are working on is iOS specific, but there's actually quite a bit of overlap in the Foundation and Core Foundation frameworks.
Edit:
If what you have is a third party library, you should be able to build it into a Cocoa framework and include that in your playground. See this link for more (somewhat out of date) information: https://pardel.dev/2018/08/10/3rd-party-frameworks-in-xcode-playgrounds/

Setup Openframework in Codeblock in Windows [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 5 years ago.
Improve this question
I would like to configure OpenFramework IDE in my codeblock. I want to build an app which prints the line on screen.
If the only thing you want is to just print a line of text you can use std::cout that prints to basic output onto your console window when the application runs. This is the most basic and easiest way to solve this.
If need to do something more complex than that, like program with GUI instead of console app, I would suggest you to use something other than OpenFrameworks, like f.e. Qt, that has a support for things like this. OpenFrameworks has the capability of doing all that, it just isn't it's main goal. You can download various addons that implement things like UI elemenets, but they are usually pretty simple.
Edit: I've just realized that by line you probably didn't mean a line of text...
Well, OpenFrameworks has no longer an Code Blocks support, you can still though download an older version from http://openframeworks.cc/download/older/

What is the best or most efficient way to develop a GUI in C++? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
I know that there are WYSIWYG editors available for GUI development, but are those the best way?
I know that in HTML if you use a WYSIWYG editor like Dreamweaver, what it produces will work but it will produce bad code that causes the program to not be as efficient as it could be.
Is it the same deal with C++ and other compiled languages?
Edit: I'll be developing for Windows 7. I probably wont be needing anything fancy like progress bars, just basic things like buttons, tick boxes, and a place to display output. It will just be running CMD commands based on what the user has selected before running it and displaying CMDs output in the program.
I guess the question I specifically wanted answered is whether it is best to "hand code" the GUI like you would in HTML, or if WYSIWYG editors are the way to go.

Visual C++ how do you debug a button click? [closed]

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 8 years ago.
Improve this question
I'm extremely new to visual c++, I thought that having the debugger be able to debug a button click would be as simple as vb/c# .net but it's clearly not :) I'm having difficulty finding anything online explaining how you debug visual C++ button clicks. Since there's no events like in VB, how does one go about doing this?
Regardless of the framework in question, or really the language in question, when debugging an application using Visual Studio you simply place a breakpoint on the line in question.
You can place a breakpoint by hitting F9 on the line you would like to stop at or by right clicking on the line and going to Breakpoint > Insert Breakpoint.
That being said, if you have no code to "handle" (in the general sense of the term, as I'm not certain what framework you're using) a button click, then you will have no code to insert a breakpoint into.

How to code a new Windows Shell? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
How would I go about coding a new Windows Vista Shell?
Everything you need to do as shell has never been documented, so there are some issues with file change notifications etc. The basics are:
SystemParametersInfo(SPI_SETMINIMIZEDMETRICS,...MINIMIZEDMETRICS) with (undocumented?) flag 8
Register as the shell (SetShellWindow,SetProgmanWindow,ShellDDEInit,RegisterShellHook etc)
Hide welcome screen by setting a signal ("msgina: ShellReadyEvent" and "ShellDesktopSwitchEvent")
Start registry run key, start menu\startup and ShellServiceObjects
Set registry Explorer\SessionInfo
The good thing is, you are not the first to write a new shell, if you look around, you can find some obscure required info. Here is a list to get you started:
https://web.archive.org/web/2019/http://www.lsdev.org/doku.php
http://bb4win.cvs.sourceforge.net/bb4win/blackbox/Blackbox.cpp?revision=1.49&view=markup
http://xoblite.net/source/Blackbox.cpp.html
http://svn.reactos.org/svn/reactos/trunk/reactos/base/shell/
http://www.geoffchappell.com/viewer.htm?doc=studies/windows/shell/explorer/index.htm&tx=36
A good place to start would be investigating how to build a command line parser, something that can tokenize and interpret the inputs. There are tools that can help with this like ANTLR, or you might like to try building your own.
Once you've parsed the inputs you need to decide what actions to take - launching processes, piping between processes, redirecting output - and making those system calls.
If you're just after a more powerful shell rather than interested in building one, give PowerShell a try.