[Tex/LaTex] QED symbol at end of special proof environment

ntheoremproof-packagetheorems

This is a follow up question to: Proof titles with ntheorem

But since the original answer-er has not been seen for a month, I'd like to ask a wider community of people.

How do you add a QED symbol to the end of the specially defined proof environment:

\usepackage{ntheorem}
\makeatletter
\newtheoremstyle{MyNonumberplain}%
  {\item[\theorem@headerfont\hskip\labelsep ##1\theorem@separator]}%
  {\item[\theorem@headerfont\hskip\labelsep ##3\theorem@separator]}
\makeatother
\theoremstyle{MyNonumberplain}
\theorembodyfont{\upshape}
\newtheorem{proof}{Proof}

Best Answer

You simply have to declare the \qedsymbol before you declare the proof environment. Sole condition for working: no blank line before \end{proof}.

This being said, I don't see why you declare a personal NoNumberPlain theorem style which is the exact copy of the already defined nonumberplain.

\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{fourier}

\usepackage[svgnames]{xcolor}

 \usepackage{amsmath, amssymb}
\usepackage[thmmarks, amsmath, thref]{ntheorem}
\usepackage{cleveref}

\theoremstyle{plain}
\theoremheaderfont{\bfseries}
\theoremseparator{.}
\theorembodyfont{\itshape}
\newtheorem{thm}{Theorem}

\makeatletter
\newtheoremstyle{MyNonumberplain}%
  {\item[\theorem@headerfont\hskip\labelsep ##1\theorem@separator]}%
  {\item[\theorem@headerfont\hskip\labelsep##1{ }##3\theorem@separator]}
\makeatother

\theoremstyle{MyNonumberplain}
\theoremheaderfont{\itshape}
\theoremseparator{. ---}
\theorembodyfont{\upshape}
\theoremsymbol{\ensuremath{\color{Gainsboro}\blacksquare}}
\newtheorem{proof}{Proof}

\begin{document}

\begin{thm}\label{th-a}
This theorem is awesome!
\end{thm}

\begin{proof}
Because I can change the position of qed mark correctly! Blahblah Blahblah Blahblah. 
\end{proof}

\begin{proof}[of \cref{th-a}]
This is a very important proof.
\begin{align*}
    a & = b\\ c & = d.
\end{align*}
\end{proof}

\end{document} 

enter image description here

Related Question