[Tex/LaTex] How adjust hat r from Griffiths David’s book

positioningsymbols

I have a difficult to center the hat bold accent as in the Griffiths David's book as the picture below extract from the book:

enter image description here

My output using

\usepackage{baskervald}
\usepackage[baskervaldx]{newtxmath}

is different to the original picture of the book.

 \documentclass[12pt,a4paper,oneside]{book}
 \usepackage[lmargin=7cm,rmargin=.7cm,bmargin=2cm,marginparwidth=5.5cm,marginparsep=2em]{geometry}
    \usepackage{lipsum,sidenotes,tabularx}
    \reversemarginpar % Page margins
    \usepackage{graphicx} % Required for including pictures
    \usepackage{xcolor}
    \usepackage{baskervald}
    \usepackage[baskervaldx]{newtxmath}
    \usepackage[scr, scaled=1.1]{rsfso}
    \usepackage{bm}
    \usepackage{amsmath,amssymb}  
    \usepackage[italian]{babel}
    \usepackage[utf8]{inputenc} 
    \usepackage[T1]{fontenc} 
    \usepackage{mathtools}
    \usepackage{dsfont}
    \usepackage{mathrsfs}
    \usepackage{scalerel}


    %----------------------------------------------------------------------------------------
    %   r Griffiths, curls and fonts from mt2pro[lite]->pro
    %----------------------------------------------------------------------------------------


    \def\rcurs{{\mbox{$\resizebox{.09in}{.08in}{\includegraphics[trim= 1em 0 14em 0, clip]{ScriptR}}$}}}
    \def\brcurs{{\mbox{$\resizebox{.09in}{.08in}{\includegraphics[trim= 1em 0 14em 0, clip]{BoldR}}$}}}
    \def\hrcurs{{\mbox{$\hat \brcurs$}}}
    \begin{document}
    \[V(\mathbf r)=\frac{1}{4\pi \epsilon_0}\int_{\mathcal V} \frac{\mathbf P(\mathbf r')\cdot \hrcurs}{\rcurs^2}d\tau'\]
    \end{document}

In fact my output is:

enter image description here

How should I fix the problem?

Best Answer

\documentclass{article}

%% Preamble
\ifdefined\pdfliteral
    \let\griffPdfliteral\pdfliteral
\else \def\griffPdfliteral#1{\special{pdf: literal #1}} \fi

\newcommand\griffr[1][2]{\leavevmode\hbox{\kern1pt\vbox to1ex{}\griffPdfliteral{%
    q 1 J .27 0 0 .27 0 0 cm #1 w
    0 2 m
    0 2 8.1 9.7 9.2 13.2 c
    10.4 16.8 8.4 15.4 8 14.7 c
    7.6 14 6.8 12.6 12 13 c
    17 13.5 14.5 7.8 13.7 6 c
    12.8 4.3 10.3 1.2 11.4 .2 c
    12.6 -.7 18.8 3.6 18.8 3.6 c
    18.8 3.6 l S Q
}\kern6pt}}
\newcommand\hatgriffr{\skew3\hat{\griffr}}

%% Body
\begin{document}
    A$\hatgriffr$B\griffr[0.5]C\griffr[3]D
\end{document}

Output

However, the values have to be manually adjusted to scale to surrounding text.