Return a std::optional<QStringView> from getAttributeId()


So it avoids QStrings completely and therefore uses the much cheaper
QStringView::slice(1) instead of QString::slice(1).

Pick-to: 6.10
Change-Id: I25eaaac10e8fbd36c28d11bf6fb925ec6ebaf897
Reviewed-by: Hatem ElKharashy <hatem.elkharashy@qt.io>
commit6e738f9f74d77f00c5914b484415863f919f6be7
parent54d6c20d1735f49ce3cb807fef75b21c2a634459
authorRobert Löhning <robert.loehning@qt.io>
committerRobert Löhning <robert.loehning@qt.io>
commit timeMon, 16 Jun 2025 09:59:09 +0200