blob: 93cc9e412d69905a33d60c0f49e0e5d34df53b90 (
about) (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
|
# Copyright (c) 2010-2024 openpyxl
def namespaced(obj, tagname, namespace=None):
"""
Utility to create a namespaced tag for an object
"""
namespace = getattr(obj, "namespace", None) or namespace
if namespace is not None:
tagname = "{%s}%s" % (namespace, tagname)
return tagname
|