cschlosser / doxdocgen

Generate doxygen documentation from source code in VS Code
https://marketplace.visualstudio.com/items?itemName=cschlosser.doxdocgen
MIT License
264 stars 55 forks source link

@brief in first line #325

Open silverhawk0007 opened 11 months ago

silverhawk0007 commented 11 months ago

Is it possible to place the generated @brief into the first line?

Actual result:

/**
 * @brief 
 * @param param1 
 * @param param2 
 * @return 
 */
int testFunction(int param1, int param2);

Expected result:

/** @brief 
 * 
 * @param param1 
 * @param param2 
 * @return 
 */
int testFunction(int param1, int param2);

Reason for this feature request: when functions are folded in VS Code, I would like to still see the @brief doxygen comment.

Actual result:

/** ...
int testFunction(int param1, int param2);

Expected result:

/** @brief ...
int testFunction(int param1, int param2);
Henu-ZhangGao commented 11 months ago

@silverhawk0007 I suppose it is correspond with you need. In order to implement, what you need to do is modify fileOrder list and firstLine string in json file as following:

"doxdocgen.file.fileOrder": [
        "empty","file","author", "version","date","copyright","custom"
    ],
"doxdocgen.c.firstLine": "/** @brief",
"doxdocgen.generic.order": [
        "empty",
        "tparam",
        "param",
        "return",
        "custom",
        "version",
        "author",
        "date",
        "copyright"
      ],