ミ,,゚Д゚彡フサギコのフサフサDelphi談話室�B
■ このスレッドは過去ログ倉庫に格納されています
0617デルファイの名無しさん
NGNGtype
ByteSet = set of 0..7;
var
ByteValue: ^ByteSet;
I, M: Integer;
ElemTypeInfo: PTypeInfo;
ElemTypeData: PTypeData;
begin
Result := '';
ElemTypeInfo := GetTypeData(TypeInfo)^.CompType^;
ElemTypeData := GetTypeData(ElemTypeInfo);
ByteValue := @Value;
for I := ElemTypeData^.MinValue to ElemTypeData^.MaxValue do
begin
M := I mod 8;
if M in ByteValue^ then
begin
if Result <> '' then
Result := Result + ',';
Result := Result + GetEnumName(ElemTypeInfo, I);
end;
if M = 7 then Inc(ByteValue)
end;
if Brackets then
Result := '[' + Result + ']';
end;
■ このスレッドは過去ログ倉庫に格納されています