MCPcopy Create free account
hub / github.com/TypesettingTools/Aegisub / GetFileName

Method GetFileName

src/ass_attachment.cpp:62–71  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

60}
61
62std::string AssAttachment::GetFileName(bool raw) const {
63 if (raw || !boost::iends_with(filename.get(), ".ttf")) return filename;
64
65 // Remove stuff after last underscore if it's a font
66 std::string::size_type last_under = filename.get().rfind('_');
67 if (last_under == std::string::npos)
68 return filename;
69
70 return filename.get().substr(0, last_under) + ".ttf";
71}

Callers 3

OnStackFrameMethod · 0.80
UpdateListMethod · 0.80
OnExtractMethod · 0.80

Calls 1

getMethod · 0.45

Tested by

no test coverage detected