父元素css添加box-sizing:border-box即可。
<style>
inline-block{display:inline-block;}
#d1{width:700px;height:300px;background:#E6941A;padding:10px;box-sizing:border-box;}
#d2{width:100%;height:200px;background:#4D9EB3;}
</style>
box-sizing:border-box;
<div id="d1">
<div id="d2"></div>
</div>
<div class="inline-block" style="background:black;color:white;width:700px;">标尺 width:700px</div>