Skip to content

Coding Style

Aman Priyadarshi edited this page Jun 21, 2016 · 10 revisions

The article describes general coding style guidelines, which should be used for Atom code. These guidelines apply exclusively to C# source files.
As much existing AtomOS code as possible should be converted to this style. Make sure you mark your progress on Styling Issue.

File Structure

  • Every AtomOS source code file should include a file header like this:
/*
* PROJECT:          Atomix Development
* LICENSE:          Copyright (C) Atomix Development, Inc - All Rights Reserved
*                   Unauthorized copying of this file, via any medium is
*                   strictly prohibited Proprietary and confidential.
* PURPOSE:          ---
* PROGRAMMERS:      Aman Priyadarshi ([email protected])
*/

You may add yourself to the PROGRAMMERS section of a file if you did a major contribution to it and could take responsibility for the whole file or a part of it.

  • Using section of C# file should follow these guidelines
    1. No unused block.
    2. Internal namespace should come before external namespaces.
    3. Internal namespaces and external namespaces should be separated by a new line.

Indentation

  • Indent with 4 spaces, don't use tabs!
Clone this wiki locally