/// <summary> /// Calling vwenv.AddObjVec() in Display() and implementing DisplayVec() seems to /// work better than calling vwenv.AddObjVecItems() in Display(). Theoretically /// this should not be case, but experience trumps theory every time. :-) :-( /// </summary> public override void DisplayVec(IVwEnv vwenv, int hvo, int tag, int frag) { ISilDataAccess da = vwenv.DataAccess; int count = da.get_VecSize(hvo, tag); for (int i = 0; i < count; ++i) { vwenv.AddObj(da.get_VecItem(hvo, tag, i), this, VectorReferenceView.kfragTargetObj); vwenv.AddSeparatorBar(); } }
/// <summary> /// Calling vwenv.AddObjVec() in Display() and implementing DisplayVec() seems to /// work better than calling vwenv.AddObjVecItems() in Display(). Theoretically /// this should not be case, but experience trumps theory every time. :-) :-( /// </summary> public override void DisplayVec(IVwEnv vwenv, int hvo, int tag, int frag) { ISilDataAccess da = vwenv.DataAccess; int count = da.get_VecSize(hvo, tag); // Tree Branches consist of everything FOLLOWING the first element which is the Tree root. for (int i = 1; i < count; ++i) { vwenv.AddObj(da.get_VecItem(hvo, tag, i), this, VectorReferenceView.kfragTargetObj); vwenv.AddSeparatorBar(); } }
/// <summary> /// Calling vwenv.AddObjVec() in Display() and implementing DisplayVec() seems to /// work better than calling vwenv.AddObjVecItems() in Display(). Theoretically /// this should not be case, but experience trumps theory every time. :-) :-( /// </summary> public override void DisplayVec(IVwEnv vwenv, int hvo, int tag, int frag) { ISilDataAccess da = vwenv.DataAccess; int count = da.get_VecSize(hvo, tag); // Show everything in the sequence including current element from the main display. for (int i = 0; i < count; ++i) { int hvoItem = da.get_VecItem(hvo, tag, i); vwenv.AddObj(hvoItem, this, VectorReferenceView.kfragTargetObj); vwenv.AddSeparatorBar(); } }
/// <summary> /// Calling vwenv.AddObjVec() in Display() and implementing DisplayVec() seems to /// work better than calling vwenv.AddObjVecItems() in Display(). Theoretically /// this should not be case, but experience trumps theory every time. :-) :-( /// </summary> public override void DisplayVec(IVwEnv vwenv, int hvo, int tag, int frag) { CheckDisposed(); ISilDataAccess da = vwenv.DataAccess; int count = da.get_VecSize(hvo, tag); // Tree Branches consist of everything FOLLOWING the first element which is the Tree root. for (int i = 1; i < count; ++i) { vwenv.AddObj(da.get_VecItem(hvo, tag, i), this, VectorReferenceView.kfragTargetObj); vwenv.AddSeparatorBar(); } }
public override void DisplayVec(IVwEnv vwenv, int hvo, int tag, int frag) { CheckDisposed(); ISilDataAccess da = vwenv.DataAccess; int count = da.get_VecSize(hvo, tag); for (int i = 0; i < count; ++i) { if (i != 0) { vwenv.AddSeparatorBar(); } vwenv.AddObj(da.get_VecItem(hvo, tag, i), this, PhoneEnvReferenceView.kFragEnvironmentObj); } }
/// <summary> /// Calling vwenv.AddObjVec() in Display() and implementing DisplayVec() seems to /// work better than calling vwenv.AddObjVecItems() in Display(). Theoretically /// this should not be case, but experience trumps theory every time. :-) :-( /// </summary> public override void DisplayVec(IVwEnv vwenv, int hvo, int tag, int frag) { ISilDataAccess da = vwenv.DataAccess; int count = da.get_VecSize(hvo, tag); // Show everything in the collection except the current element from the main display. for (int i = 0; i < count; ++i) { int hvoItem = da.get_VecItem(hvo, tag, i); if (m_displayParent != null && hvoItem == m_displayParent.Hvo) { continue; } vwenv.AddObj(hvoItem, this, VectorReferenceView.kfragTargetObj); vwenv.AddSeparatorBar(); } }
public override void DisplayVec(IVwEnv vwenv, int hvo, int tag, int frag) { CheckDisposed(); ISilDataAccess da = vwenv.DataAccess; int count = da.get_VecSize(hvo, tag); for (int i = 0; i < count; ++i) { if (i != 0) vwenv.AddSeparatorBar(); vwenv.AddObj(da.get_VecItem(hvo, tag, i), this, PhoneEnvReferenceView.kFragEnvironmentObj); } }
public override void DisplayVec(IVwEnv vwenv, int hvo, int tag, int frag) { CheckDisposed(); ISilDataAccess da = vwenv.DataAccess; switch (frag) { default: { Debug.Assert(false, "Unrecognized fragment."); break; } case ReversalIndexEntrySliceView.kFragIndices: { // hvo here is the sense. int countRows = da.get_VecSize(hvo, tag); Debug.Assert(countRows == m_usedIndices.Count, "Mismatched number of indices."); for (int i = 0; i < countRows; ++i) { vwenv.OpenTableRow(); int idxHvo = da.get_VecItem(hvo, tag, i); vwenv.AddObj(idxHvo, this, ReversalIndexEntrySliceView.kFragIndexMain); vwenv.CloseTableRow(); } break; } case ReversalIndexEntrySliceView.kFragEntries: { int wsHvo = 0; foreach (IReversalIndex idx in m_usedIndices) { if (idx.Hvo == hvo) { wsHvo = idx.WritingSystemRAHvo; break; } } Debug.Assert(wsHvo > 0, "Could not find writing system."); int wsOldDefault = this.DefaultWs; this.DefaultWs = wsHvo; // hvo here is a reversal index. int countEntries = da.get_VecSize(hvo, ReversalIndexEntrySliceView.kFlidEntries); for (int j = 0; j < countEntries; ++j) { if (j != 0) vwenv.AddSeparatorBar(); int entryHvo = da.get_VecItem(hvo, ReversalIndexEntrySliceView.kFlidEntries, j); vwenv.AddObj(entryHvo, this, ReversalIndexEntrySliceView.kFragEntryForm); } this.DefaultWs = wsOldDefault; break; } } }
/// <summary> /// Calling vwenv.AddObjVec() in Display() and implementing DisplayVec() seems to /// work better than calling vwenv.AddObjVecItems() in Display(). Theoretically /// this should not be case, but experience trumps theory every time. :-) :-( /// </summary> public override void DisplayVec(IVwEnv vwenv, int hvo, int tag, int frag) { ISilDataAccess da = vwenv.DataAccess; int count = da.get_VecSize(hvo, tag); // Show everything in the collection except the current element from the main display. for (int i = 0; i < count; ++i) { int hvoItem = da.get_VecItem(hvo, tag, i); if (m_displayParent != null && hvoItem == m_displayParent.Hvo) continue; vwenv.AddObj(hvoItem, this, VectorReferenceView.kfragTargetObj); vwenv.AddSeparatorBar(); } }