none
winform gmap 随着鼠标滚动,改变字体大小 RRS feed

  • 问题

  • 想实现第一幅图不显示自定义的字体,随着鼠标滚动在显示字体,向第二幅图一样


    please verify my account

    2017年1月23日 2:16

答案

  • 已实现
         private void gMapControl1_OnMapZoomChanged()
            {
                if (_my_mark != null)
                {
                    if (gMapControl1.Zoom >= 7)
                    {
                        for (int i = 0; i < _my_mark.Markers.Count; i++)
                        {
                            ((GMarkerArrow)_my_mark.Markers[i]).StationName = ((GMarkerArrow)_my_mark.Markers[i]).StationName1;
                        }
                    }
                    else {
    
                        for (int i = 0; i < _my_mark.Markers.Count; i++)
                        {
                            ((GMarkerArrow)_my_mark.Markers[i]).StationName = null;
                        }
                    }
                }
    
            }


    please verify my account

    • 已建议为答案 Bob Ding 2017年1月23日 10:50
    • 已标记为答案 lctk 2017年2月20日 10:23
    2017年1月23日 3:22

全部回复

  • 已实现
         private void gMapControl1_OnMapZoomChanged()
            {
                if (_my_mark != null)
                {
                    if (gMapControl1.Zoom >= 7)
                    {
                        for (int i = 0; i < _my_mark.Markers.Count; i++)
                        {
                            ((GMarkerArrow)_my_mark.Markers[i]).StationName = ((GMarkerArrow)_my_mark.Markers[i]).StationName1;
                        }
                    }
                    else {
    
                        for (int i = 0; i < _my_mark.Markers.Count; i++)
                        {
                            ((GMarkerArrow)_my_mark.Markers[i]).StationName = null;
                        }
                    }
                }
    
            }


    please verify my account

    • 已建议为答案 Bob Ding 2017年1月23日 10:50
    • 已标记为答案 lctk 2017年2月20日 10:23
    2017年1月23日 3:22
  • Hi,

    如果你的问题已经解决,请及时标记有用的回复作为答案,这样会帮助其他遇到相同问题的人。

    Best Regards,

    Hart


    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    2017年2月20日 9:16
    版主
  •  请问   _my_mark   这个是怎么定义的?
    2019年12月5日 3:17
  • 你这"测试"两个字怎么显示出来的啊,请指教。
    2019年12月5日 10:48