update parsing of microsoft vendorlist webpage
(issue
@@ -558,8 +558,18 @@ def registered_vendor_ids():
'data/fontbakery-microsoft-vendorlist.cache')
content = open(CACHED).read()
soup = BeautifulSoup(content, 'html.parser')
- table = soup.find(id="VendorList")
+
+ IDs = [chr(c + ord('a')) for c in range(ord('z') - ord('a') + 1)]
+ IDs.append("vendor-id-and-name-list")
+
+ for section_id in IDs:
+ section = soup.find('h2', {'id': section_id})
+ table = section.find_next_sibling('table')
+ if not table: continue
+
+ #print ("table: '{}'".format(table))
for row in table.findAll('tr'):
+ #print("ROW: '{}'".format(row))
cells = row.findAll('td')
# pad the code to make sure it is a 4 char string,
# otherwise eg "CF " will not be matched to "CF"
