Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
C++ Application Development with Code::Blocks

You're reading from   C++ Application Development with Code::Blocks Using Code::Blocks it's possible for C++ developers to create application consistency across multiple platforms. This book takes you through the process from installation to implementing advanced features, all with a user-friendly approach.

Arrow left icon
Product type Paperback
Published in Oct 2013
Publisher
ISBN-13 9781783283415
Length 128 pages
Edition Edition
Languages
Arrow right icon
Author (1):
Arrow left icon
BIPLAB MODAK BIPLAB MODAK
Author Profile Icon BIPLAB MODAK
BIPLAB MODAK
Arrow right icon
View More author details
Toc

Management of code snippets


Code::Blocks allows developers to store and retrieve frequently used code snippets. We have used DoxyBlocks plugin in our previous example to comment blocks suitable for generating documents. However we can also save a blank template as a code snippet and reuse it wherever needed.

  1. Go to View | Code snippets menu option to show the CodeSnippets window.

  2. Right-click on the codesnippets in the tree and select Add SubCategory menu option.

  3. Name it doxygen. Right-click on this doxygen category and click on the Add snippet menu option.

  4. Enter Block comment as Label and following code as the snippet text:

    \** \brief
      *
      */
  5. Click on the OK button to save this snippet. CodeSnippets window will look similar to the following screenshot:

  6. Now click on any place in the Code::Blocks editor window, right-click on this snippet and select Apply menu option. This snippet will now be pasted into the Editor window.

We can add code, bookmarks, text files as a code snippet. Code snippets are not project specific and works across all the projects.

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image