+ RTFGetToken( info );
+
+ if (info->rtfClass == rtfText)
+ {
+ if (level == 1)
+ {
+ if (!buffer)
+ size = read_hex_data( info, &buffer );
+ }
+ else
+ {
+ RTFSkipGroup( info );
+ }
+ } /* We potentially have a new token so fall through. */
+
+ if (info->rtfClass == rtfEOF) return;
+
+ if (RTFCheckCM( info, rtfGroup, rtfEndGroup ))
+ {
+ if (--level == 0) break;
+ continue;
+ }
+ if (RTFCheckCM( info, rtfGroup, rtfBeginGroup ))
+ {
+ level++;
+ continue;
+ }
+ if (!RTFCheckCM( info, rtfControl, rtfPictAttr ))
+ {
+ RTFRouteToken( info );
+ if (RTFCheckCM( info, rtfGroup, rtfEndGroup ))
+ level--;
+ continue;
+ }
+
+ if (RTFCheckMM( info, rtfPictAttr, rtfWinMetafile ))
+ {
+ mfp.mm = info->rtfParam;
+ gfx = gfx_metafile;
+ }
+ else if (RTFCheckMM( info, rtfPictAttr, rtfDevIndBitmap ))
+ {
+ if (info->rtfParam != 0) FIXME("dibitmap should be 0 (%d)\n", info->rtfParam);
+ gfx = gfx_dib;
+ }
+ else if (RTFCheckMM( info, rtfPictAttr, rtfEmfBlip ))
+ gfx = gfx_enhmetafile;
+ else if (RTFCheckMM( info, rtfPictAttr, rtfPicWid ))
+ mfp.xExt = info->rtfParam;
+ else if (RTFCheckMM( info, rtfPictAttr, rtfPicHt ))
+ mfp.yExt = info->rtfParam;
+ else if (RTFCheckMM( info, rtfPictAttr, rtfPicGoalWid ))
+ sz.cx = info->rtfParam;
+ else if (RTFCheckMM( info, rtfPictAttr, rtfPicGoalHt ))
+ sz.cy = info->rtfParam;
+ else
+ FIXME("Non supported attribute: %d %d %d\n", info->rtfClass, info->rtfMajor, info->rtfMinor);