지도 스타일을 맞춤설정할 때 다양한 지도 지형지물의 스타일을 지정하는 것이 지도의 다른 스타일에 어떤 영향을 미치는지 이해하면 도움이 됩니다. 다음과 같이 몇 가지 겹치는 레이어가 있습니다.
기본 지도: 지도 스타일을 만들기 시작하면 기본 지도의 스타일, 즉 기본 지도가 초기 지도로 표시됩니다. 맞춤설정하지 않은
지도 지형지물은 기본 지도 스타일을 유지합니다.
지도 스타일: 맞춤 스타일은 기본 지도 레이어의 스타일을 재정의합니다.
이 이미지에서는 맞춤 지도 스타일이 도시 지역은 청록색으로,
도로는 진한 파란색으로 재정의합니다.
스타일 요소: 각 지도 지형지물에는 맞춤설정할 수 있는 스타일 요소가 하나 이상 있습니다. 이 이미지에서 도시 지역 지도 지형지물의 다각형 채우기 색상은
청록색으로 지정되어 있고, 도로망 채우기 색상은
파란색으로 지정되어 있습니다.
지도 지형지물 계층
지도 스타일 내에서 지도 지형지물은 계층적으로 구성됩니다. 상단에는 광범위한 지도 지형지물 4개가 있고 그 아래에 다른 모든 지도 지형지물이 논리적 계층 구조로 정렬됩니다. 기본적으로, 지도 지형지물은 계층 구조에서 그 위에 있는
지도 지형지물(상위 요소)의 요소 스타일을 상속합니다. 그러나 그 아래에 있는 지도 지형지물(하위 지도 지형지물)의 스타일 요소를 하나 이상 설정하여
최상위 스타일을 재정의할 수 있습니다. 지도 지형지물 계층에 대한 자세한 내용은
지도에서 스타일을 지정할 수 있는 항목을 참고하세요.
각 지도 지형지물에는 스타일을 지정할 수 있는 하나 이상의 요소 또는
지도 지형지물의 부분이 있습니다. 예를 들어 다각형(지도 지형지물 도형)의 채우기 색상은 하나의 요소이며
텍스트 라벨의 획 색상도 마찬가지입니다. 각 요소의 스타일을
개별적으로 지정할 수 있으며, 스타일을 지정하지 않은 요소에는
기본 스타일이 유지됩니다. 요소들은 서로 별개이므로, 라벨 텍스트의 채우기 색상에는
스타일을 지정하고 획(윤곽선) 색상은 기본값(또는 상위 스타일에서 상속한 값)으로
둘 수 있습니다.
다음은 스타일 계층 구조 및 상속의 원리를 이해하는 데 유용한 가이드라인입니다.
기본 하위 스타일은 상위 스타일 상속: 모든 하위 지도 지형지물이
스타일을 상속하도록 하려면 상위 지도 지형지물의 스타일을 지정하고 하위 스타일은
기본값으로 둡니다.
맞춤 하위 스타일은 상위 스타일 재정의: 상위 스타일이 재정의되도록 하려면
하위 지형지물에 맞춤 스타일을 지정합니다.
스타일 요소는 독립적임: 지도 지형지물에 설정할 수 있는
스타일 요소(예: 다각형, 라벨 아이콘, 라벨 텍스트 채우기 및 획)는
서로 독립적입니다. 다각형 색상을 설정하고
아이콘은 그대로 두면, 다각형 스타일은 상위 스타일보다 우선 적용되지만
아이콘은 상위 스타일 또는 기본 스타일을 상속합니다.
공개 상태를 사용 중지하여 지도 지형지물 숨기기: 지도에서 한 가지 항목만 보려면
다른 모든 항목의 공개 상태를 사용 중지해야 합니다.
계층 구조와 상속의 예시
다음은 상속 및 계층 구조가 작동하는 방식의 예시입니다.
자연의 최상위 지도 지형지물을 선택하고
다각형 채우기 색상을 노란색으로 설정합니다. 이렇게 하면 자연의 하위 지형지물에
대한 모든 다각형의 스타일이 노란색으로 지정됩니다.
자연의 하위 지형지물인 토지피복도 노란색으로 표시하기 위해
토지피복에 스타일을 지정하지 않고 자연의 스타일을 상속하도록 합니다.
숲을 녹색으로 지정하기 위해 토지피복에서 숲을 열고
해당하는 다각형을 녹색으로 지정합니다. 이 맞춤 하위 스타일은
토지피복 및 자연의 스타일을 재정의합니다.
빙하를 옅은 청록색으로 표시하기 위해 역시 토지피복에서
빙하를 열고 해당하는 다각형을 옅은 청록색으로 지정합니다.
마지막으로 수역을 청록색으로 표시하기 위해 자연 > 수역을 선택하고
해당하는 다각형을 청록색으로 지정합니다. 하위 항목인 수역의 스타일을 지정하면 상위 항목인
자연의 스타일이 재정의됩니다.
[null,null,["최종 업데이트: 2025-08-27(UTC)"],[],[],null,["Select platform: [Android](/maps/documentation/android-sdk/cloud-customization/map-hier \"View this page for the Android platform docs.\") [iOS](/maps/documentation/ios-sdk/cloud-customization/map-hier \"View this page for the iOS platform docs.\") [JavaScript](/maps/documentation/javascript/cloud-customization/map-hier \"View this page for the JavaScript platform docs.\") [Web Service](/maps/documentation/maps-static/cloud-customization/map-hier \"View this page for the Web Service platform docs.\")\n\n\u003cbr /\u003e\n\nWhen you customize a map style, it helps to understand how styling different map\nfeatures may affect other styles on the map. There are several layers that\noverlap:\n\n- **The base map**: When you start creating a map style, the initial\n you see is the style of the base map; that is, the default map. Any map\n features you don't customize retain the base map styling.\n\n- **Map styles**: Custom styles override the styles on the base map layer.\n In this image, the custom map style overrides the urban areas as aqua\n and roads as dark blue.\n\n- **Style elements**: Each map feature has one or more style elements that\n you can customize. In this image, the urban areas map feature polygon\n fill color is styled as aqua, and the road network fill color\n is styled as blue.\n\nMap feature hierarchy\n\nWithin a map style, map features are organized hierarchically, with 4 broad\nmap features at the top, and all other map features arranged beneath them in\na logical hierarchy. By default, a map feature inherits the element styles\nfor the map feature above it in the hierarchy (its parent); however, you\ncan override the top level style by setting one or more of the style elements\nfor map features underneath it (child map features). For details on the map\nfeature hierarchy, see [What you can style on a map](/maps/documentation/javascript/cloud-customization/taxonomy).\n\nEach map feature has one or more elements, or parts of the map feature, that\nyou can style. For example, the fill color for the polygon (the map feature\nshape) is an element, as is the stroke color for the text label. You style\neach element separately, and any element you don't style retains the default\nstyle. Since elements are separate, you can style the fill color for label\ntext, and leave the stroke (outline) color as the default (or inheriting\nfrom a parent style).\n\nHere are some helpful guidelines in understanding how style hierarchy and\ninheritance work.\n\n- **Default child styles inherit from the parent**: To have all\n child map features inherit a style, set the style for the parent map feature,\n and leave the child style as the default.\n\n- **Custom child styles override the parent**: To override the parent style,\n set a custom style on the child feature.\n\n- **Style elements are independent**: The style elements you can set for a\n map feature (for example, the polygon, the label icon, and the label text\n fill and stroke) are independent from each other. If you set the polygon\n color, but leave the icon alone, the polygon style overrides the parent\n style, but the icon inherits the parent or default style.\n\n- **Turn off Visibility to hide map features**: If you want to see only one\n thing on your map, you have to turn off visibility for everything else.\n\n | **Note:** When you hide map features or make them semi-transparent, you may expose boundary inaccuracies. Map feature boundaries are not always precise, but are adjusted to look correct when all layers are visible. For more details, see [Manage styles that overlap](/maps/documentation/javascript/cloud-customization/overlap).\n\nHierarchy and Inheritance Example\n\nHere is an example of how inheritance and hierarchy works.\n\n1. Select the top-level map feature of **Natural** , and set the\n **Polygon Fill color** to yellow. This styles all polygons for map\n features under **Natural** to be yellow:\n\n2. You want **Land cover** , which is under **Natural** , to also be yellow,\n so you leave it unstyled, and it inherits the style from **Natural**.\n\n3. You want forests to be green, so under **Land cover** , you open **Forest** ,\n and color its polygon green. This custom child style overrides the\n styles for **Land cover** and **Natural**.\n\n4. You want ice to be shown a pale aqua, so also under **Land cover** , you\n open **Ice**, and color its polygon pale aqua.\n\n5. And last, you want water to be aqua, so you select **Natural\\\u003eWater** , and\n color its polygon aqua. Setting the child style **Water** overrides the parent\n style for **Natural**.\n\nFollow a similar process to highlight the map features for your needs."]]