Below you can see the front-view size comparison of the Leica M10 and Leica Q2. The Leica M10 is 41 mm shorter and 12 mm thinner than the Leica Q2 but it is also 9 mm wider.
The chart below depicts how two cameras compare with average dimensions of the cameras in their class.